";
// Fetch all factory records
$strQuery111 = " SELECT * FROM $myTable2 WHERE Teacher_code='$Teacher_code' GROUP BY $myTableGroup ORDER BY $myTableOrder DESC ";
$result111 = $dbObj->execQuery($strQuery111);
//Iterate through each factory
if( $result111 ) {
while( $rs111 = $dbObj->fetchArray($result111) ) {
$Year = $rs111['Year'];
$strQuery222 = " SELECT * FROM history_absent_tb WHERE Teacher_code='$Teacher_code' AND Year='$rs111[Year]' ";
$result222 = $dbObj->execQuery($strQuery222);
$numAmt222 = $dbObj->_numrows;
$dbObj->freeresult($result222);
$strXML .= "";
} # while
} # if
$dbObj->freeresult($result111);
//Finally, close element
$strXML .= "";
//Create the chart - Pie 3D or Column3D Chart with data from strXML
echo renderChart("../charts/Column3D.swf", "", $strXML, "", 760, 375, false, false);
?> |