You Are Here:
TopCountry MusicCountry Song Lyric > Country Song Lyric Msg52508

Country Song Lyric

=?iso-8859-1?Q?Table=20Design?=
Date: Wed, 5 Mar 2003 01:24:42 +0000 (UTC)
Newsgroups: mailing.database.mysql
Size: 1,987 bytes
Hello,
I`m doing a database in MySQL to catalog cds, and i`m not sure if my tabl=
e
structure is the best way to do it:
Artist Table Artist_Id int unsigned not null auto_increment primary key Name char(120) // Artist or Band Name Country char(30) // Artist Or Band Country Members char(255) // Band Members Biography text // Artist or Band History
CDS Table CD_Id int unsigned not null auto_increment primary key Artist_Id int unsigned not null Title char(150) // CD Title Style char(150) // CD Style Year year(4) // CD Release Year
Song Table CD_Id int unsigned not null Position tinyint // Song position on cd Name char ( 255 ) // Song Name length char(10) // Song Length lyric text // Song Lyric
Is it the best structure and relationship for my database?
Some exemples
If i try to find the a artist name i can search for artist name
in artist table, but if i want to know what cds a artist got?
SELECT * from CDS WHERE Artist_Id =3D SOMENUMBER
but if i don`t know the artist id then i need to do a search for the id
first?
So is not better use artist name to my primary key?
And in same way use CD title as primary key in cd table
and in song table?
But it's not a waste of space??
I`m a bit new in database so sometimes i get a bit confude
about structure and my frontend program will be a java gui to serch and
insert things in database so i`m trying to make easy as possible.
Thank You.
------------------------------------------
Use o melhor sistema de busca da Internet
Radar UOL - http://www.radaruol.com.br
---------------------------------------------------------------------
Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <email-address-deleted>
To unsubscribe, e-mail <mysql-unsubscribe-mysql=email-address-deleted>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Site Categories:
• Broadway
• Child Song
• Christian Music
• Classical Music
• Country Music
• Dance
• Gospel Music
• Guitar Music
• Jazz
• Karaoke
• Lyric
• Metal Music
• Music
• Music Download
• Music Video
• New Age
• Rap Music
• Reggae
• Rock
• Wedding Song
• World Music