PHP 4.0 Bug #2922: mysql_result doesn't work with tables

From: Date: Mon, 06 Dec 1999 10:18:20 +0000
Subject: PHP 4.0 Bug #2922: mysql_result doesn't work with tables
Groups: php.dev 
Request: Send a blank email to php-dev+get-13465@lists.php.net to get a copy of this message
From: hrauch@help-pi.f.shuttle.de Operating system: Linux 2.2.10 PHP version: 4.0 Beta 3 PHP Bug Type: MySQL related Bug description: mysql_result doesn't work with tables With php 3.12 the following lines worked very well: $result3 = mysql ( "schul_db" , "SELECT spf.TextKey " . "FROM Schulst_SprFolge=st_spf,Key_Sprachenfolge=spf " . "WHERE (st_spf.StelleID='$st_id') AND (st_spf.CodeKey=spf.CodeKey)" ); $num3 = mysql_numrows ( $result3 ); $i3 = 0; WHILE ( $i3 < $num3 ) { $sprachenfolge = mysql_result ( $result3 , $i3 , "spf.TextKey" ); ... $i3 ++; }  With 4.0 B3 this warning is displayed: Warning: spf not found in MySQL result index 4 in /home/www/doc/schule/schul-db/index.php3 on line 192 If I remove "spf.", everything is fine: $sprachenfolge = mysql_result ( $result3 , $i3 , "TextKey" ); On the other hand, the following lines - with the same logical structure as above - were executed without any error: $result4 = mysql ( "schul_db" , "SELECT * FROM Schulst_Vorausse=st_vor, Key_Voraussetzung=vor " . "WHERE (st_vor.StelleID='$st_id') AND (st_vor.CodeKey=vor.CodeKey)" ); $num4 = mysql_numrows ( $result4 ); $i4 = 0; $voraus = ""; WHILE ( $i4 < $num4 ) { $vor = mysql_result ( $result4 , $i4 , "vor.TextKey" ); .. $i4 ++; }

« previous php.dev (#13465) next »