Hi all,

First post, so be gentle :)

I have a query which is more complex (taking advantage of relational
databases more) than I have ever done before... and I'm not sure where in
the docs to be looking for examples.

I have three tables...

cd (id, title, etc)
artist (id, name)
cd_to_artist (cdid, artistid)

Given an artist id, I want to retrieve all cds related to that artist, given
the information in the table cd_to_artist.  The reason for the third table
is because more than one artist can be related to a CD (compilations, etc).

Should I be looking at JOIN? or is it something more complex in the WHERE,
or am I way off track?


Any links to articles, FAQs, etc etc, or query snippets would be greatly
appreciated...  I'm using MySQL in conjunction with PHP if that helps...


Justin French





---------------------------------------------------------------------
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

Reply via email to