PEAR DB, autoExecute and errorhandling
| From: | Christian Joergensen | Date: | Tue, 20 Apr 2004 16:01:33 +0000 |
| Subject: | PEAR DB, autoExecute and errorhandling | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-11980@lists.php.net to get a copy of this message | ||
Hello
I just recovered from a three hour bughunt from a rather weird
error-reporting from PEAR DB.
Imagine the following code:
1: $dbh->autoExecute('table1', $data1);
2: $dbh->autoExecute('table2', $data_nonexistant);
The variable '$data_nonexistant' is non-existant and thus should raise
an error. It does so; a DB_ERROR_NEED_MORE_DATA. However the error is
based on the old query from the command on line 1, printing out the
correct generated query, giving a lot of problems finding the actual
error.
Is there any technical documentation (design documents?) covering the
OOD of PEAR DB?
I just looked at the code quickly in order to maybe make a patch to fix
the problem but at a first glance it seems quite complex :-)
Thank you :-)
--
Christian Jørgensen, CTO
GMTA ApS - Edvard Falcks Gade 1 - DK-1569 Koebenhavn V - Denmark
Phone: +45 70231337 - Fax: +45 70271337 - http://www.gmta.info