Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 2.5.0b5

Bug #4695 Bug with prepare and execute
Submitted: 2005-06-28 13:07 UTC
From: danielr at electroteque dot org Assigned: lsmith
Status: Closed Package: MDB2
PHP Version: 5.0.3 OS: N/A
Roadmaps: (Not assigned)    
Subscription  


 [2005-06-28 13:07 UTC] danielr at electroteque dot org
Description: ------------ When I upgraded MDB2 I experienced a bug that I only just discovered. when i start a prepare statement execute is requiring i add a types array its not checking if $this->types is an array or not and breaking on me Reproduce code: --------------- $this->prepare = $this->_db->prepare('query ...); $this->prepare->bindArray($data); $this->prepare->execute(); I have to do this $this->prepare = $this->_db->prepare('query ...,array()); Actual result: -------------- <font color="#ff0000"><tt><b>Warning</b>: key(): Passed variable is not an array or object (/Volumes/DATA/www/ classes/PEAR/MDB2.php at line 3029)<br /> (/Volumes/DATA/www/classes/PEAR/MDB2.php at line 3029)<br /> (/Volumes/DATA/www/classes/PEAR/MDB2.php at line 3007)<br /> $types_numeric = is_numeric(key($this->types));

Comments

 [2005-06-29 12:08 UTC] smith at backendmedia dot com
This bug has been fixed in CVS. In case this was a documentation problem, the fix will show up at the end of next Sunday (CET) on pear.php.net. In case this was a pear.php.net website problem, the change will show up on the website in short time. Thank you for the report, and for helping us make PEAR better.