Bug #1611: odbc_num_rows() can't get rows num

From: Date: Mon, 28 Jun 1999 09:21:31 +0000
Subject: Bug #1611: odbc_num_rows() can't get rows num
Groups: php.dev 
Request: Send a blank email to php-dev+get-7674@lists.php.net to get a copy of this message
From: wjw@hongzhi.com Operating system: winNT PHP version: 3.0.11 PHP Bug Type: ODBC related Bug description: odbc_num_rows() can't get rows num i use odbc_num_rows() can't get rows num only get -1 follow the code i use odbc get dbase & SQL dbase can't get num rows //open dbase $db = odbc_connect("db", "wjw", "wjw"); $result = odbc_exec($db, "SELECT * FROM n64 where etitle like '%'"); echo odbc_num_fields($result)."<br>"; echo odbc_num_rows($result)."<br>"; for ($i=1; $i<=150; $i++) { if (odbc_fetch_row($result, $i)) echo odbc_result($result, 3)."<br>"; } //echo odbc_result_all($result, ""); odbc_close($db); //open ms sql server $db = odbc_connect("ss", "sa", ""); $result = odbc_exec($db, "SELECT * FROM authors"); echo odbc_num_fields($result)."<br>"; echo odbc_num_rows($result)."<br>"; for ($i=1; $i<=150; $i++) { if (odbc_fetch_row($result, $i)) echo odbc_result($result, 4)."<br>"; } //echo odbc_result_all($result, ""); odbc_close($db);

« previous php.dev (#7674) next »