Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:68031 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 54242 invoked from network); 2 Jul 2013 08:46:51 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 2 Jul 2013 08:46:51 -0000 Authentication-Results: pb1.pair.com smtp.mail=php@beccati.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=php@beccati.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain beccati.com designates 176.9.114.167 as permitted sender) X-PHP-List-Original-Sender: php@beccati.com X-Host-Fingerprint: 176.9.114.167 spritz.beccati.com Received: from [176.9.114.167] ([176.9.114.167:35871] helo=mail.beccati.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 4C/80-49923-A7392D15 for ; Tue, 02 Jul 2013 04:46:50 -0400 Received: (qmail 27459 invoked from network); 2 Jul 2013 08:46:45 -0000 Received: from home.beccati.com (HELO ?192.168.1.202?) (88.149.176.119) by mail.beccati.com with SMTP; 2 Jul 2013 08:46:45 -0000 Message-ID: <51D29355.9040807@beccati.com> Date: Tue, 02 Jul 2013 10:46:13 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/20130509 Thunderbird/17.0.6 MIME-Version: 1.0 To: Yasuo Ohgaki CC: "internals@lists.php.net" References: <51CAB115.60602@beccati.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] pgsql: Binary data support improvement From: php@beccati.com (Matteo Beccati) On 26/06/2013 11:51, Yasuo Ohgaki wrote: > Hi Matteo, > > PDO_pgsql on the other hand, when used with explicit parameter binding, > could automatically use binary format for LOB fields. > > AFAIK, PDO doesn't handle bytea data natively. It does, as far as I remember. See PDO::PARAM_LOB We could easily (and transparently) use binary for the parameters explicitly bound as LOB, but I see no way we can use binary for results -- which usually is the most common operation. Maybe it's better than nothing though? > There may be clever usage, but binary support is only for faster bytea > handling. > API isn't great, so if there are objections, I'll spend time rather than > this. I think the API would become cumbersome and error-prone, although I see the benefits in bytea-intensive scenarios. My vote is: +0 If we only could figure out a better API, that could turn into a +1... Cheers -- Matteo Beccati Development & Consulting - http://www.beccati.com/