Well, if you want your main table to have foreign keys into the tables that maintain your other data (Studios, Genres, Actors, etc) then you need to populate your other tables first. You will be referring to those tables when you perform your inserts into your main table to gain access to the correct IDs.
David -----Original Message----- From: John Chang [mailto:johnec@;umich.edu] Sent: Thursday, October 17, 2002 9:09 AM To: [EMAIL PROTECTED] Subject: input data which table first SQL, Does it matter which table I enter data into first? Or do I need to first put in the data into Studios, Genres, Actors, & Stars first before adding to Titles and TitleGenres since they use the IDs of the other table? Or should I convert it to type innodb and make the IDs foreign keys in the Titles and TitleGenres. And if I do that then will the database allow me to enter data into Titles or TitleGenre if the data isn't already in the other tables? Thank you. The database type is MYISAM. Studios (StudioName, StudioID) Genres (GenreName, GenreID) Titles (VideoTitle, Details, StudioID, GenreID, BitRateID, TitleID) Actors (F_Name, L_Name, ActorID) Stars (TitleID, ActorID) TitleGenres (TitleID, GenreID) --------------------------------------------------------------------- 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 PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php --------------------------------------------------------------------- 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 PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php