重複の可能性:
mysql_fetch_array() は、パラメーター 1 がリソースであると想定しており、select でブール値が指定されています
私は持っている :
$connector = new DBconnector();
$sql = "SELECT school.name, student-.ClassSize_7, student-.ClassSize_8, degree_o.degree_code, accredit.full_faculty_3,
accredit.total_faculty_3, accredit.pc_terminal, accredit.stud_fac_ratio, fresh_en.num_appl_offered, fresh_en.num_appl_received FROM school
INNER JOIN student- ON school.scid = student-.scid
INNER JOIN degree_o ON school.scid = degree_o.scid
INNER JOIN accredit ON school.scid = accredit.scid
INNER JOIN fresh_en ON school.scid = fresh_en.scid
ORDER BY school.name ASC LIMIT 0, 25";
$result = $connector->query($sql);
//$numberRows = $connector->numRows($result);
$numRows = mysql_num_fields($result);
そして、私のクエリは結果を返さず、次のような警告が表示されます:
Warning: mysql_num_fields() expects parameter 1 to be resource, boolean given in C:\wamp\www\...\academics.php on line 17
と
Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in C:\wamp\www\...\academics.php on line 96
理由がわかりません、誰か助けてください