I'm fairly new to MySQL and very new to PHP. I'm trying to access multiple tables, but it's just too hairy for me to do in one call. But I tried multiples and it isn't working.
This message here further confuses me:
Here's a quick and simplified look at it. Is there anything that would prevent me from doing this? I realize the mysql_fetch_assoc would be put in a loop. I should mention that if I comment out the first 2 queries, I get about 20 rows of data. When I put the 2 queries in, I get just one row, but the $number_of_rows shows a totally bogus number (like 2200 or something).
Thanks
$linkID = @mysql_connect("localhost","user","pw");
mysql_select_db ("db",$linkID);
$resultID = mysql_query($select_statement_1,$linkID);
$x=mysql_fetch_assoc($resultID);
$resultID = mysql_query($select_statement_2,$linkID);
$y=mysql_fetch_assoc($resultID);
$resultID = mysql_query($select_statement_3,$linkID);
$z=mysql_fetch_assoc($resultID);
$numer_of_rows = mysql_num_rows($resultID);
This message here further confuses me:
Here's a quick and simplified look at it. Is there anything that would prevent me from doing this? I realize the mysql_fetch_assoc would be put in a loop. I should mention that if I comment out the first 2 queries, I get about 20 rows of data. When I put the 2 queries in, I get just one row, but the $number_of_rows shows a totally bogus number (like 2200 or something).
Thanks
$linkID = @mysql_connect("localhost","user","pw");
mysql_select_db ("db",$linkID);
$resultID = mysql_query($select_statement_1,$linkID);
$x=mysql_fetch_assoc($resultID);
$resultID = mysql_query($select_statement_2,$linkID);
$y=mysql_fetch_assoc($resultID);
$resultID = mysql_query($select_statement_3,$linkID);
$z=mysql_fetch_assoc($resultID);
$numer_of_rows = mysql_num_rows($resultID);