note 89482 added to function.odbc-num-rows

From: Date: Tue, 10 Mar 2009 12:10:34 +0000
Subject: note 89482 added to function.odbc-num-rows
Groups: php.notes 
Request: Send a blank email to php-notes+get-151681@lists.php.net to get a copy of this message
I think the best way to determine the count of the returned rows is the following code: <?php $counter = 0; while(odbc_fetch_row($row)) { $name=odbc_result($row,1); $price=odbc_result($row,2); $quantity=odbc_result($row,3); $counter++; } print "The count of the returned rows is ".$counter; ?> It works fine for me. ---- Server IP: 217.75.128.29 Probable Submitter: 93.152.158.227 ---- Manual Page -- http://www.php.net/manual/en/function.odbc-num-rows.php Edit -- https://master.php.net/note/edit/89482 Del: integrated -- https://master.php.net/note/delete/89482/integrated Del: useless -- https://master.php.net/note/delete/89482/useless Del: bad code -- https://master.php.net/note/delete/89482/bad+code Del: spam -- https://master.php.net/note/delete/89482/spam Del: non-english -- https://master.php.net/note/delete/89482/non-english Del: in docs -- https://master.php.net/note/delete/89482/in+docs Del: other reasons-- https://master.php.net/note/delete/89482 Reject -- https://master.php.net/note/reject/89482 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#151681) next »