Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:10028 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 14498 invoked by uid 1010); 22 May 2004 15:38:59 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 14433 invoked from network); 22 May 2004 15:38:58 -0000 Received: from unknown (HELO hamlet) (80.126.21.70) by pb1.pair.com with SMTP; 22 May 2004 15:38:58 -0000 Received: from [127.0.0.1] ([127.0.0.1]) by hamlet with Microsoft SMTPSVC(6.0.2600.1106); Sat, 22 May 2004 17:38:42 +0200 Message-ID: <40AF7400.7040909@ewi.tudelft.nl> Date: Sat, 22 May 2004 17:38:40 +0200 User-Agent: Mozilla Thunderbird 0.6 (Windows/20040502) X-Accept-Language: en-us, en MIME-Version: 1.0 To: internals@lists.php.net CC: helly@php.net, ilia@prohost.org, wez@thebrainroom.net, george@omniti.com Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 22 May 2004 15:38:42.0899 (UTC) FILETIME=[DCAADA30:01C44012] Subject: pdo design From: a.k.biesheuvel@ewi.tudelft.nl (Ard Biesheuvel) Guys, I saw the alpha of PDO on pecl. I was wondering if we could discuss the design of it a bit more before putting too much work into it. In particular, the way transactions are represented is not very practical. Generally, databases that support transactions will support multiple concurrent transactions against the same database. Firebird also supports transactions against multiple databases. [which does *not* mean you can join tables from different DBs, it just means ACID over multiple DBs] This means that in some cases you must specify both the connection and the transaction when generating a statement. [I'm not sure if others RDBMSs support this, but it might be something we will see more in the future.] In short: In addition to $db->startTransaction(), maybe we could add PDO::startTransaction($db1 [,$db2 [,$db3]]). In addition to $db->prepare(), maybe we could add a Transaction interface whose instances would allow being called as $trans->prepare($query) and maybe even $trans->prepare($db, $query) Your thoughts please ? -- Ard