$sectionb_total_score = 0; $Year = date('Y'); $mySQL2 = 'SELECT COUNT(A.id) as TotalID, SUM(A.total_score) as TotalScore, A.year_assessment FROM assessment_technical A INNER JOIN assessment_year B ON A.assessment_year_id = B.id WHERE A.year_assessment = B.year_assessment AND A.staff_id =' .$data['staff_id'] ; $result2 = mysql_query($mySQL2); if ($result2){ if (mysql_num_rows($result2) > 0){ $row2 = mysql_fetch_assoc($result2); $sectionb_total_score = $row2['TotalScore'] / $row2['TotalID']; } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)