#26590 [Opn->Bgs]: mssql_num_rows()
ID: 26590
Updated by: sniper@php.net
Reported By: bhavin dot shah at cgi dot com
-Status: Open
+Status: Bogus
Bug Type: MSSQL related
Operating System: Windows
PHP Version: 4.3.4
New Comment:
You need to check that passed parameters are valid.
No bug here.
Previous Comments:
------------------------------------------------------------------------
[2003-12-11 00:04:54] bhavin dot shah at cgi dot com
Description:
------------
As per the documentation, mssql_num_rows() returns the number of rows
in a result set. It works fine, if stored procedure returns some
records. But it gives following error when stored procedure returns
nothing (empty recordset).
mssql_num_rows(): supplied argument is not a valid MS SQL-result
resource
mssql_num_rows() should return 0, when no records are returned from
stored procedure.
It seems that the problem is with mssql_execute(). It does not return
any Resource ID, if the result is empty. Hence, mysql_num_rows() fails
which expects Resource ID as the parameter.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=26590&edit=1
Thread (2 messages)