> Ron Korving wrote: > > > 1) Does unsetting $stmt trigger a closeCursor() as well? I assume so, but > > the article doesn't mention it. It only talks about the importance of > > calling that method. > > yes this is done automatically ..
Great :) > > 2) Could it be a good idea (performance wise) and possible in the first > > place to maintain a pool of prepared statements? Something like this: > > This should be done on the RDBMS end. I havent looked at how PDO does > this in detail, but it would be nice to get some more control over this. > Some RDBMS will pool this automatically, some do not (AFAIK pgsql will > always create a new statement instead of returning a handle to an > existing statement). There is a reason why you may want more control > over this. One of the key aspects of a prepared statement is that you > safe time due to not having to build a query plan on every execution. > This may bite you however if you prepare a statement and then things > change within the database that would make it more feasible to use a new > plan. It would be very nice if this was indeed done by the RDBMS. That would mean you don't have to "remember" any prepared statements yourself and would definately benefit the performance a great deal. > > 3) Wouldn't it be nice if you could do a $stmt->execute("foo", "bar"); > > (numeric parameters) instead of $stmt->execute(array("foo", "bar")); ? > > I think this would severely hurt the extensibility of the API not only > for PDO itself, but also for people who want to transparently extend the > API. Good point, I take that back. > regards, > Lukas Thanks, Ron ________________________________________ Scanned and protected by SecureMail v2.2 http://www.axit.nl -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php