[lyric_item image]
lyric_item
A lyric_item record encapsulates the data definition of the xs:choice section of the lyric complexType in the MusicXML schema.
The lyric_item table is single-inheritance, discriminator column lyric_item_type. Disciminator values are:
  • lyric text
  • extend
  • laughing
  • humming
A lyric text record has a list of lyric syllables stored in the lyric_syllable table, foreign key lyric_text_id.
When the first subelement of a lyric element is either syllabic or text, the lyric element's subelements are iterated, and when a text element is reached, the elision, syllabic, and text elements up to that point are aggregated into a lyric_syllable record. The iteration then continues, creating any other lyric syllable records until the lyric element's subelements are exhausted.
Finally, if there is a trailing extend element, an extend record is added to the lyric_item table, and self-joined to the lyric text using foreign key extend_id (both the extend and the lyric text are stored in the lyric_item table).
Display info for an extend lyric item type is joined directly from the lyric_item table using foreign key display_id. Display info for a text is handled via the lyric_syllable table where the text data is stored.
An extend record can also belong to a figure record. The foreign key in the figure table is extend_id.