RE: Stumped I Tell You!

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



[snip]
 [snip!]
>
> $endBal = mysql_fetch_array($dbEnd);
> echo mysql_num_rows($dbEnd);
> print_r($endBal);
>
> Nothing gets returned from those last statements. Am I missing
something
> completely?

    Right here....

<?php
// Code before....
if(!$dbEnd = (mysql_query($getEnd, $dbc))){
       echo mysql_error() . "\n";
       exit();
}
// .... code after....
?>

    You're merging assignment.  Maybe you meant this:

<?php
if(($dbEnd = mysql_query($getEnd, $dbc)) === FALSE) {
    echo mysql_error() . "\n";
    exit();
}
?>
[/snip]

I have several other queries running in this example and they all use
the same run/error check routine with no issues. This has always worked
in the past. It is like saying if(!$theFile = fopen('myfile.txt', 'a'))

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux