Mysql
 sql >> Database >  >> RDS >> Mysql

mysql_num_rows() si aspetta che il parametro 1 sia risorsa, booleano dato in C:\wamp\www

$s=mysql_query("select semester from faculty_advisor where emp_id = 'macs410' ");
echo $s;
$subject=mysql_query("select * from subject_list where semester=$s");

Should be

$s=mysql_query("select semester from faculty_advisor where emp_id = 'macs410' ");
$row = mysql_fetch_assoc($s); 
$subject=mysql_query("select * from subject_list where semester='".$row['semester']."'");