Re: syntax error

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

 



    Please keep replies on list for all to benefit and be able to assist.

On Mon, Jul 21, 2008 at 5:47 PM, Ronald Wiplinger <tm.ronald@xxxxxxxxx> wrote:
>
> On Tue, Jul 22, 2008 at 1:51 AM, Daniel Brown <parasane@xxxxxxxxx> wrote:
>>
>>    Try this:
>>
>> >    $result = mysql_query($sql,$db) or die(mysql_error());

    Did you try my suggestion above?  If so, did you receive any errors?

> echo "result=$result<br>";
>     $num=mysql_num_rows($result);
> echo "num=$num";
>
> I get:
>
> result=
> num=

    The most you'd get from $result in this case would be a resource
identifier message, because that's all mysql_query() returns.  And
since the resource link doesn't seem to be correctly established, $num
will be empty.

-- 
</Daniel P. Brown>
Better prices on dedicated servers:
Intel 2.4GHz/60GB/512MB/2TB $49.99/mo.
Intel 3.06GHz/80GB/1GB/2TB $59.99/mo.
Dedicated servers, VPS, and hosting from $2.50/mo.

-- 
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