Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:16277 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 6698 invoked by uid 1010); 18 May 2005 15:01:42 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 71286 invoked from network); 18 May 2005 14:36:13 -0000 Received: from unknown (HELO pb1.pair.com) (127.0.0.1) by localhost with SMTP; 18 May 2005 14:36:13 -0000 X-Host-Fingerprint: 81.97.205.128 spc1-hava1-4-0-cust128.cosh.broadband.ntl.com Linux 2.5 (sometimes 2.4) (4) Received: from ([81.97.205.128:34372] helo=waiter.telford.lan) by pb1.pair.com (ecelerity 1.2 r(5656M)) with SMTP id 5F/54-01538-AD25B824 for ; Wed, 18 May 2005 10:36:10 -0400 Received: from [192.168.0.30] (unknown [192.168.0.30]) by waiter.telford.lan (Postfix) with ESMTP id 78033390885; Wed, 18 May 2005 15:36:07 +0100 (BST) Received: from 127.0.0.1 (AVG SMTP 7.0.308 [266.11.12]); Wed, 18 May 2005 15:36:04 +0100 Message-ID: <428B52D4.6070208@ntlworld.com> Date: Wed, 18 May 2005 15:36:04 +0100 User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Lukas Smith Cc: internals@lists.php.net References: <20050518132615.55570.qmail@lists.php.net> <428B40D7.8030903@php.net> In-Reply-To: <428B40D7.8030903@php.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: Allow PDO::query() to return a subclass of PDOStatement From: nick.telford@ntlworld.com (Nicholas Telford) Lukas Smith wrote: > Nicholas Telford wrote: > >> What I'm proposing is to allow PDO::query() to return a subclass of >> PDOStatement. This would allow abstractions to tailor the result set >> to their own needs while not (in theory) being too complicated to >> implement. >> >> My initial idea involves passing an object that is a subclass of >> PDOStatement into PDO:query as a second parameter, then all that >> would be needed to get it to return a custom result set would be >> something like this: > > > http://oss.backendmedia.com/index.php?area=PDO&page=FAQ > > read the last item over there. > > Marcus (IIRC) is planning on making this less clumsy as right now you > have to repeatedly specifiy the statement class you want AFAIK. > > regards, > Lukas > > Ah thank you, I understand that PDO is still under development, I thought I may as well mention this before the cement dries so to speak. Good to see that this has already been thought of and an implementation already exists (even if it's not ideal).