Re: Re: MDB2_Driver_pgsql MDB2_PORTABILITY_RTRIM bug?

From: Date: Tue, 18 Jul 2006 14:26:54 +0000
Subject: Re: Re: MDB2_Driver_pgsql MDB2_PORTABILITY_RTRIM bug?
References: 1 2 3  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-24683@lists.php.net to get a copy of this message
Il 16:03, martedì 18 luglio 2006, Lukas Smith ha scritto: > > Ok please file a bug report for this. > Be sure to paste your SQL and test code. http://pear.php.net/bugs/bug.php?id=8239. Please find also here the test code in case my home server is down: Thank you --------------------------------------- define('DBHOST', 'localhost'); define('DBDRIVER', 'pgsql'); define('DBUSER', '****'); define('DBPASSWORD', '***'); define('DBPORT', '5432'); define('DBNAME', 'bugtest'); // Build the DSN $dsn = DBDRIVER . '://' . DBUSER . ':' . DBPASSWORD . '@' . DBHOST . ( DBPORT ? ':' . DBPORT : '') . '/' . DBNAME; // Create a MDB2 object named $mdb2 require_once 'MDB2.php'; $options = array( 'debug' => 2, 'portability' => MDB2_PORTABILITY_RTRIM ); //MDB2_PORTABILITY_RTRIM $mdb2 =& MDB2::connect($dsn); if (PEAR::isError($mdb2)) { die($mdb2->getMessage() . '<br />' . $mdb2->getUserInfo()); } $res =& $mdb2->query('DROP TABLE bug'); $res =& $mdb2->query('CREATE TABLE bug ( driver_id serial NOT NULL, driver character(50) )'); if(PEAR::isError($res)){ die($res->getMessage() . '<br />' . $res->getUserInfo()); } $res =& $mdb2->query("INSERT INTO bug (driver_id, driver) VALUES (7, 'GDAL/PNG')"); if(PEAR::isError($res)){ die($res->getMessage() . '<br />' . $res->getUserInfo()); } $res =& $mdb2->query("SELECT * FROM ntbl_driver"); if(PEAR::isError($res)){ die($res->getMessage() . '<br />' . $res->getUserInfo()); } $row = $res->fetchRow(MDB2_FETCHMODE_ASSOC); var_dump($row); -- Alessandro Pasotti -- itOpen - "Open Solutions for the Net Age" w3: www.itopen.it Linux User# 167502

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