Re: MDB2 ibase Reverse: strange case problem

From: Date: Wed, 02 May 2007 15:01:39 +0000
Subject: Re: MDB2 ibase Reverse: strange case problem
References: 1 2  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-27178@lists.php.net to get a copy of this message
Il 16:00, mercoledì 2 maggio 2007, Lorenzo Alberton ha scritto: > Ciao Alessandro, > > > after switching from DB to MDB2 within DB_DataObject I run into this > > error: > > > > Fatal error: Cannot use object of type MDB2_Error as array > > in /usr/share/php/DB/DataObject/Generator.php on line 262 > > > > Digging in the code, I've tracked the error to > > MDB2/Driver/Reverse/ibase.php: > > > > if (!$index['unique_flag'] && !$index['foreign_key']) > > { > > > > return $db->raiseError(MDB2_ERROR_NOT_FOUND, null, null, > > 'it was not specified an existing table constraint', > > __FUNCTION__); > > } > > > > > > The error is triggered by $index keys being uppercase while the check > > for 'unique_flag' and 'foreign_key' is lower case, there are some > > instruction to set $fields keys to lower case but no options to lower > > case the $index too. > > can you try the CVS version? > AFAICS, this issue should not happen in > the latest revision. Now testing the latest CVS, I have another error (note that everything works with DB instead of MDB2). Error message: 'APPALTI_UF_OPER_T_IDX1' is not an existing table constraint this comes from line 365 in Reverse/ibase.php. The index APPALTI_UF_OPER_T_IDX1 does not exists. Any hint on how to debug this? A dump of $lastrow is: array(6) { ["field_name"]=> string(5) "IDSAL" ["unique_flag"]=> int(0) ["foreign_key"]=> NULL ["description"]=> NULL ["constraint_type"]=> NULL ["field_position"]=> string(1) "1" } -- Alessandro Pasotti itOpen - "Open Solutions for the Net Age" w3: www.itopen.it Linux User# 167502

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