Submissions.php: capitalize SQL commands

Bug430-Eden2
Lan Hui 2023-09-03 20:35:19 +08:00
parent f740ed9a03
commit 4292652e9b
1 changed files with 5 additions and 5 deletions

View File

@ -63,23 +63,23 @@ echo "<div><a href='Courses.php?course=$url'> $header </a></div>";
$_SESSION['info_Marking'] = null;
}
$resultx1 = mysqli_query($con, "Select Count(*) as cnt from lab_report_submissions where lab_report_submissions.Lab_Report_ID=$id");
$resultx1 = mysqli_query($con, "SELECT Count(*) AS cnt FROM lab_report_submissions WHERE lab_report_submissions.Lab_Report_ID=$id");
$row = mysqli_fetch_assoc($resultx1);
$count_submissions = $row['cnt'];
$resultx2 = mysqli_query($con, "Select COUNT(*) as cnt from lab_report_submissions where lab_report_submissions.Lab_Report_ID=$id and Status='Marked'");
$resultx2 = mysqli_query($con, "SELECT COUNT(*) AS cnt FROM lab_report_submissions WHERE lab_report_submissions.Lab_Report_ID=$id and Status='Marked'");
$row = mysqli_fetch_assoc($resultx2);
$count_marked = $row['cnt'];
$resultx3 = mysqli_query($con, "Select COUNT(*) as cnt from lab_report_submissions where lab_report_submissions.Lab_Report_ID=$id and Status='Pending'");
$resultx3 = mysqli_query($con, "SELECT COUNT(*) AS cnt FROM lab_report_submissions WHERE lab_report_submissions.Lab_Report_ID=$id and Status='Pending'");
$row = mysqli_fetch_assoc($resultx3);
$count_unmarked = $row['cnt'];
$resultx4 = mysqli_query($con, "Select COUNT(*) as cnt from lab_report_submissions where lab_report_submissions.Lab_Report_ID=$id and Status='Remarking'");
$resultx4 = mysqli_query($con, "SELECT COUNT(*) AS cnt FROM lab_report_submissions WHERE lab_report_submissions.Lab_Report_ID=$id and Status='Remarking'");
$row = mysqli_fetch_assoc($resultx4);
$count_remark = $row['cnt'];
$resultx5 = mysqli_query($con, "SELECT COUNT(*) as cnt FROM course_groups_table WHERE Course_id=$c_id");
$resultx5 = mysqli_query($con, "SELECT COUNT(*) AS cnt FROM course_groups_table WHERE Course_id=$c_id");
$row = mysqli_fetch_assoc($resultx5);
$count_group = $row['cnt'];