-
Notifications
You must be signed in to change notification settings - Fork 39
Schema
The mbrainz-sample schema is an adaptation of a subset of the full MusicBrainz schema. We didn't include some entities, and we made some simplifying assumptions and combined some entities. In particular:
- We omit any notion of Work
- We combine Track, Tracklist and Recording into simply "track"
- We renamed Release group to "abstractRelease"
NOTE: abstractRelease data are omitted from the 1968-1973 subset database.
(Adapted from the MusicBrainz schema docs)
An "abstractRelease" is an abstract "album" entity (e.g. "The Wall" by Pink Floyd). A "release" is something you can buy in your music store (e.g. the 1984 US vinyl release of "The Wall" by Columbia, as opposed to the 2000 US CD release by Capitol Records).
Therefore, when you query for releases e.g. by name, you may see duplicate releases. To find just the "work of art" level album entity, query for abstractRelease.
The media are the physical components comprising a release (disks, CDs, tapes, cartridges, piano rolls). One medium will have several tracks, and the total tracks across all media represent the track list of the release.
NOTE: abstractRelease data are omitted from the 1968-1973 subset database.
attribute | type | cardinality |
---|---|---|
:abstractRelease/name | indexed string | one |
:abstractRelease/artistCredit | fulltext string | one |
:abstractRelease/gid | uniquely identifying, indexed uuid | one |
:abstractRelease/type | enum ref, one of:
|
one |
:abstractRelease/artists | ref | many |
attribute | type | cardinality |
---|---|---|
:artist/startYear | indexed long | one |
:artist/startMonth | long | one |
:artist/startDay | long | one |
:artist/endYear | long | one |
:artist/endMonth | long | one |
:artist/endDay | long | one |
:artist/sortName | indexed string | one |
:artist/name | indexed, fulltext string | one |
:artist/gid | uniquely identifying, indexed uuid | one |
:artist/country | ref | one |
:artist/type | enum ref, one of:
|
one |
:artist/gender | enum ref, one of:
|
one |
attribute | type | cardinality |
---|---|---|
:country/name | unique string | one |
attribute | type | cardinality |
---|---|---|
:label/startYear | indexed long | one |
:label/startMonth | long | one |
:label/startDay | long | one |
:label/endYear | long | one |
:label/endMonth | long | one |
:label/endDay | long | one |
:label/sortName | indexed string | one |
:label/name | indexed, fulltext string | one |
:label/gid | uniquely identifying, indexed uuid | one |
:label/country | ref | one |
:label/type | enum ref, one of:
|
one |
attribute | type | cardinality |
---|---|---|
:language/name | unique string | one |
attribute | type | cardinality |
---|---|---|
:medium/position | long | one |
:medium/trackCount | long | one |
:medium/format | enum ref, one of:
|
one |
:medium/tracks | component ref | many |
attribute | type | cardinality |
---|---|---|
:release/year | indexed long | one |
:release/month | long | one |
:release/day | long | one |
:release/artistCredit | fulltext string | one |
:release/status | indexed string | one |
:release/barcode | string | one |
:release/name | indexed, fulltext string | one |
:release/gid | uniquely identifying, indexed uuid | one |
:release/artists | ref | many |
:release/abstractRelease | ref | one |
:release/language | ref | one |
:release/media | component ref | many |
:release/packaging | enum ref, one of:
|
one |
:release/script | ref | one |
:release/label | ref | one |
:release/country | ref | one |
attribute | type | cardinality |
---|---|---|
:script/name | unique string | one |
attribute | type | cardinality |
---|---|---|
:track/position | long | one |
:track/duration | indexed long | one |
:track/artistCredit | fulltext string | one |
:track/name | indexed, fulltext string | one |
:track/artists | ref | many |