Cecily,
I think yuo need to specify the fields within the tables when you write
out a select query from multiple tables like this.
For example:
SELECT artist_name.*, album_title.* .
FROM artists, album_titles WHERE artist_name.artist_id = aid);
Hope this works,
Michael
Cecily Walker
SELECT artist_name, album_title FROM album_titles LEFT JOIN artist
USING(aid) WHERE artist_id = aid
-Original Message-
From: Michael Egan [mailto:[EMAIL PROTECTED]]
Sent: Monday, September 17, 2001 8:22 AM
To: [EMAIL PROTECTED]; Cecily Walker Kidd
Subject: [PHP-DB] Re: NEWBIE - Needs
Cecily,
I'm sure you probably heard from others about your parse error. I know
it looks weird, but you need to have two semicolons, so instead of:
$CDList =mysql_query(
SELECT artist_name, album_title .
FROM artists, album_titles WHERE artist_id = aid);
you would have
$CDList =mysql_query(
You should not need the extra semicolon in there to complete the SQL
statement. All you need is the one at the end.
Vera Algoet [EMAIL PROTECTED] said:
Cecily,
I'm sure you probably heard from others about your parse error. I know
it looks weird, but you need to have two semicolons, so
-
From: Vera Algoet [EMAIL PROTECTED]
To: [EMAIL PROTECTED]; Cecily Walker Kidd [EMAIL PROTECTED]
Sent: Monday, September 17, 2001 12:10 PM
Subject: [PHP-DB] Re: NEWBIE - Needs Assistance with Joins
Cecily,
I'm sure you probably heard from others about your parse error. I know
it looks weird
You said you get a parse error - so I'm assuming that is a PHP parse error,
not an SQL error. Can you attach the entire problem file to an e-mail and
send it to me, along with the exact error message? I have a feeling that it
is something to do with the way you are retrieving the results in your
:11 PM
To: [EMAIL PROTECTED]; Cecily Walker Kidd
Subject: [PHP-DB] Re: NEWBIE - Needs Assistance with Joins
Cecily,
I'm sure you probably heard from others about your parse error. I know
it looks weird, but you need to have two semicolons, so instead of:
$CDList =mysql_query(
SELECT