execQuery($sql);
$rs6= $dbObj->fetchArray($result6);
$strXML = "";
// Fetch all factory records
$strQuery = " SELECT * FROM course_results Where coseId ='$coseId' Order BY AcademicYear ASC ";
$result5 = $dbObj->execQuery($strQuery);
//Iterate through each factory
if ($result5) {
while( $rs5 = $dbObj->fetchArray($result5) ) {
$sql3 = " SELECT SUM(Results) AS SumB1 FROM course_results WHERE coseId='$rs5[coseId]' and AcademicYear='$rs5[AcademicYear]' ";
$result3 = $dbObj->execQuery($sql3);
$rs3 = $dbObj->fetchArray($result3);
$strXML .= "" ;
} # while
} # if
//Finally, close element
$strXML .= "";
//Create the chart - Pie 3D Chart with data from strXML
echo renderChart("../charts/Column3D.swf", "", $strXML, "", 650, 305, false, false);
?> |
|