#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Dec 2001
    Posts
    12
    Rep Power
    0

    Question Storing Guitar Songs in a Database


    Hello all,

    I am wondering if anyone knows of a good way to store/organize guitar music in a database. This would include lyric text, guitar tabulature and how the two are coordinated. Does anyone have any ideas?

    Thanks in advance
  2. #2
  3. Contributing User
    Devshed Intermediate (1500 - 1999 posts)

    Join Date
    Oct 2001
    Location
    New Zealand
    Posts
    1,774
    Rep Power
    24
    Hmm, a long list of chords per track?

    Well, two simple tables:

    TRACKID NUMERIC,
    LYRICS BLOB,
    GUITAR_TAB BLOB

    and a look-up table:

    CHORDID NUMERIC,
    FINGER_PATTERN VARCHAR(5) ... assuming you use five fingers.

    Would store the data.

    GUITAR_TAB could be a long sequence of two digit numbers from 00 (a rest) upwards that represent a CHORDID in the look-up table. This way you simply do a while loop in your program to get all the chords back.

    Now, as you rightly say, you need to calculate the coordination of the two... hence you need to replicate some sequencing method such as Cubase where each value is given a duration. This is easy for the guitar tabliture as you simply add another two digits to the two for the chord, these two representing the duration. How you do the duration of the lyrics though is something I can't work out. Possibly you give each word a duration, but then it makes the adding and extraction of lyrics a complicated one, no simple cut and paste job. When extracting the lyrics you have to somehow get the figure and the word separate, not impossible but not easy.

    Any help?
  4. #3
  5. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2002
    Posts
    5
    Rep Power
    0
    Hi Bradym3,

    Based on the info provided, two tables would exist. One table for the guitar tabs and one for the lyric text. When you say database, hopefully that is a reference to a SQL DBMS with relational qualities. The reason why is so you query information from both tables. Anyway the most important part is having a surrogate key (a computer created unique identifier), which exist in both tables (same surrogate key in both tables). That way if the lyric text changes and the guitar tab does not, then you can update the lyric text table without creating any update anomalies and vice versa. The two tables are connected via the surrogate key, which provides referential intergrity.

    Regards,

IMN logo majestic logo threadwatch logo seochat tools logo