below is a handy function i inherited that (in the old mysql) allowed a single rowXcolumn (scalar) value to be returned
by using a one-line function call (instead of $results = and then $row['fieldname'] = the value you want)
with mysqli it is returning the error shown at the bottom.
any help with what was not updated properly for mysqli conventions?
$NumLineItems = db_sql("SELECT COUNT(*) FROM tblSales_order_details WHERE so_header_key = 30 ");
function db_sfq ($query)
$result = db_sql($query); // this function works fine
$row = mysqli_fetch_array($result);
return $row; // only one field scalar was requested
}// end db_SingleFieldQuery
Catchable fatal error: Object of class mysqli_result could not be converted to string