[PDO] Transaction with select statement?
| From: | php at jochen-vajda dot de | Date: | Sat, 05 Nov 2005 15:15:24 +0000 |
| Subject: | [PDO] Transaction with select statement? | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-40596@lists.php.net to get a copy of this message | ||
Hi,
Is it possible to do a transaction with a select statement in PDO?
BEGIN
INSERT INTO (...) VALUES (...)
SELECT MAX(id) ....
COMMIT
Because PDO::lastInsertId is not working with all database driver and exec() does not return the resultset?
Or can you name which database drivers support lastInsertId?
Regards,
Jochen Vajda
--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/