connect_errno) { echo "db connection error : " . $mysql->connect_error; exit(); } ?> /*these php blocks do not need to be separated, but might as well since in many pages with full/normal html likely this block would be lower down in the code*/ query($sql); if(!$results) { echo "SQL error: ". $mysql->error . " running query
" . $sql . "
"; exit(); } // since only query in the page, and just a single line query (one row) that // does not need a loop, pre-load the query columns into $currentrow $currentrow = $results->fetch_assoc(); // dump columns into source code of page to debug / see column names and data echo ""; ?> /* */
Patients summary report:
Condition:

Number of Patients:

Average age:

Lowest age:

Highest age: