Re: Pear Db layer

From: Date: Sat, 30 Sep 2000 17:28:05 +0000
Subject: Re: Pear Db layer
References: 1 2  Groups: php.pear 
Request: Send a blank email to php-pear+get-306@lists.php.net to get a copy of this message
Quoting Richard Heyes <php@heyes-computing.net>: > Ok, after some more ploughing, I've got this: > > $data = $result->fetchRow(MYSQL_ASSOC); > > Presumably this should return an associative array of a row. Only it > returns an enumerated array. And this returns an associative instead of > an enumerated: > > $data = $result->fetchRow(MYSQL_NUM); > > Bug? You're using the wrong constants. Use DB_GETMODE_ASSOC for associative, and DB_GETMODE_ORDERED for enumerated. -chuck -- Charles Hagenbuch, <chuck@horde.org> -- may kittens pounce in your dreams

« previous php.pear (#306) next »