Problem with DB

From: Date: Fri, 13 Sep 2002 10:11:07 +0000
Subject: Problem with DB
Groups: php.pear.general 
Request: Send a blank email to pear-general+get-2295@lists.php.net to get a copy of this message
I make a project using PEAR DB, in start i use MySQL, in a object table i use: $res = $db->query("SELECT * ....."); $cols = $res->tableInfo(); _ _ _ while($row = $res->fetchRow()) {
        _
        _
} $res->free(); And this work fine, but if i change the database to Postgress, it fails and don't return any data, and the problem is the $cols = $res->tableInfo(); call, if i comment this out the result returns the rows, for solve this problem temporally, i use this method, but it seem no eficient, anybody have the same trouble. $res = $db->query("SELECT * ....."); $cols = $res->tableInfo(); $res->free(); $res = $db->query("SELECT * ....."); _ _ _ while($row = $res->fetchRow()) {
        _
        _
} $res->free(); Any help will be apreciated. Regards ----------------------------------------------- Marcos Lois Bermúdez marcos.lois@iqc-services.com IQC - Services Avda. Garcia Barbón, 90 / 4ºB 36201 Vigo (Pontevedra) Tel: +34 986.884.244 Fax: +34 986.415.074 http://www.iqc-services.com -----------------------------------------------

« previous php.pear.general (#2295) next »