PHP 4.0 Bug #5219: PG_Fetch_Array won't work with associative reference
| From: | rmsilva_br at yahoo dot com | Date: | Sun, 25 Jun 2000 03:26:46 +0000 |
| Subject: | PHP 4.0 Bug #5219: PG_Fetch_Array won't work with associative reference | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-22256@lists.php.net to get a copy of this message | ||
From: rmsilva_br@yahoo.com
Operating system: Linux
PHP version: 4.0 Release Candidate 2
PHP Bug Type: PostgreSQL related
Bug description: PG_Fetch_Array won't work with associative reference
The scenario is described here:
mydb=> create table test ( name char(50), phone char(8) );
mydb=> insert int test values ('Renato', '3434343');
query.php:
<?
$conn = pg_connect("dbname=mydb");
$result = pg_exec($conn, "select name, phone from test")
$arr = pg_fetch_array($result, 0);
echo $arr["name"];
?>
( nothing gets printed out. but if I use $arr[0] I get 'Renato')