HOME > PHP > PHP Forum > รบกวนที่ค่ะ Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in C:\AppServ\www\student\details.php on line 146
รบกวนที่ค่ะ Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in C:\AppServ\www\student\details.php on line 146
<?
include ("connect.php");
$id=$_GET["id"];
$SqlReal="Select student1.std_id, student1.std_name, student1.std_surname, student1.std_department, central_c_falculty.FAC_NAME_THAI From student1, std_extra_job, central_c_falculty Where (student1.std_id = std_extra_job.std_id) And (student1.FAC_ID=central_c_falculty.FAC_ID) And (extra_job_id=".$id.") And (backUp_state=False) Order By std_extra_job.submit_date, std_extra_job.submit_time";
$Sql_Real= mysql_query($SqlReal);
while ($rsReal=mysql_fetch_array($Sql_Real))
{
$s_num=$s_num+1;
$SqlReal="Select student1.std_id, student1.std_name, student1.std_surname, student1.std_department, central_c_faculty.FAC_NAME_THAI FROM student1
LEFT JOIN std_extra_job ON student1.std_id= std_extra_job.std_id
LEFT JOIN central_c_faculty ON student1.std_department=central_c_faculty.FAC_ID
WHERE extra_job_id=".$id." And (backUp_state=False) Order By std_extra_job.submit_date, std_extra_job.submit_time";
$Sql_Real= mysql_query($SqlReal);