Update query to return mysqli_result
FIXES T175