RE: [PHP-DB] Problem with pg_fetch_array

From: Date: Mon, 23 Oct 2006 23:25:06 +0000
Subject: RE: [PHP-DB] Problem with pg_fetch_array
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-42588@lists.php.net to get a copy of this message
show relevant code around the query and attempt to loop thru resultset bastien
From: Vignesh M P N <manivig@iit.edu> To: php-db@lists.php.net Subject: [PHP-DB] Problem with pg_fetch_array Date: Mon, 23 Oct 2006 15:12:25 -0500 Hi I am trying to display the rows from a database table in a grid. I retrieved the results using pg_query() with a Select command. pg_query() returns true. But when I pass the results $rows to pg_fetch_array(), it returns false. I even tried displaying the error, if any, using: pg_fetch_array($rows) or die('fetch array failed: ' . pg_last_error()); I also tried pg_result_error(), but both didn't display error. It just displays "fetch array failed: ", but it doesn't display any error. When the pg_query() returns a result, I wonder why pg_fetch_array() is not able to iterate through the rows. I am new to this PHP database stuff, please help me in this. Thanks Vignesh.
_________________________________________________________________ Ready for the world's first international mobile film festival celebrating the creative potential of today's youth? Check out Mobile Jam Fest for your a chance to WIN $10,000! www.mobilejamfest.com

« previous php.db (#42588) next »