From: olivier at pipas dot org
Operating system: Windows XP
PHP version: 5.0.4
PHP Bug Type: ODBC related
Bug description: Bug select odbc_fetch_row
Description:
------------
I do a select in a db access (odbc), it return good number of rows but
cannot show it
Reproduce code:
---------------
if(!$conn=odbc_connect("mydbodbc","user","pass"))
exit("Error connect DB");
$sql="SELECT numcountry, namecountry FROM countries;";
if(!$res=odbc_exec($conn,$sql))
exit("Error syntax : $sql");
$i=0;
while($restab=odbc_fetch_row($res))
{
echo $restab;
echo "$restab[0] $restab[1]<br>\n";
$i++;
}
echo $i;
Expected result:
----------------
Array1 Belgium<br>
Array2 France<br>
Array3 Spain<br>
3
Actual result:
--------------
1 <br>
1 <br>
1 <br>
3
--
Edit bug report at http://bugs.php.net/?id=33238&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=33238&r=trysnapshot4
Try a CVS snapshot (php5.0):
http://bugs.php.net/fix.php?id=33238&r=trysnapshot50
Try a CVS snapshot (php5.1):
http://bugs.php.net/fix.php?id=33238&r=trysnapshot51
Fixed in CVS: http://bugs.php.net/fix.php?id=33238&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=33238&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=33238&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=33238&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=33238&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=33238&r=support
Expected behavior: http://bugs.php.net/fix.php?id=33238&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=33238&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=33238&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=33238&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=33238&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=33238&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=33238&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=33238&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=33238&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=33238&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=33238&r=mysqlcfg