note 69997 deleted from function.odbc-num-rows by bobby

From: Date: Fri, 29 Sep 2006 15:18:07 +0000
Subject: note 69997 deleted from function.odbc-num-rows by bobby
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-117837@lists.php.net to get a copy of this message
Note Submitter: Miroslav Reason: bad code ---- //I did it my way: //--------------- <?php $conn = odbc_connect ('odbc_name', 'user_name', 'password') or die ('Could NOT connect to ODBC database!'); $query = ('select * from table_name..column_name') $result = odbc_exec($conn,$query); if (odbc_error()) { echo odbc_errormsg($conn); } $number_of_rows = 0; while (odbc_fetch_into($result, &$row)) { print $row[0]."</br>"; $number_of_rows++; } print "</br>"; print $number_of_rows; odbc_free_result($result); odbc_close($conn); ?>

« previous php.notes (#117837) next »