Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:67608 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 33931 invoked from network); 2 Jun 2013 14:17:09 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 2 Jun 2013 14:17:09 -0000 Authentication-Results: pb1.pair.com header.from=php@beccati.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=php@beccati.com; spf=pass; 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:59582] helo=mail.beccati.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 46/E5-32744-2E35BA15 for ; Sun, 02 Jun 2013 10:17:07 -0400 Received: (qmail 19278 invoked from network); 2 Jun 2013 14:17:02 -0000 Received: from home.beccati.com (HELO ?192.168.1.202?) (88.149.176.119) by mail.beccati.com with SMTP; 2 Jun 2013 14:17:02 -0000 Message-ID: <51AB53D2.1030705@beccati.com> Date: Sun, 02 Jun 2013 16:16:50 +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: PHP internals Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: PDO_pgsql improvements and fixes From: php@beccati.com (Matteo Beccati) Hi, after quite some some I've been finally able to put my hands again on PDO. I know the timing is not ideal, but I hope it's not too late for adding a couple more features and fixes into 5.5. Namely: - LISTEN/NOTIFY support https://bugs.php.net/42614 - Additional support for COPY https://bugs.php.net/50092 The former is Postgres' own Publish–subscribe messaging system, which is already supported by the regular pgsql extension, but it's not available for those using PDO. The latter adds low-level functionality to read/write data to tables without having to rely on arrays or files as in the existing PDO::pgsqlCopyFromArray etc. Again, something that exists in the pgsql ext, but not within PDO. Both features have been ported to 5.5 and are mostly code complete, but while cleaning them up I've noticed something rather unpleasant. It appears that error handling in all the existing custom PDO::pgsql* methods is kind of broken, as they doesn't effectively use PDO's pdo_handle_error() function, thus they don't trigger any error or exception at all. I still think it's worth to fix this for 5.5, and possibly backport the fixes, but this requires some refactoring to move PDO_HANDLE_DBH_ERR() and related declarations/macros away from php_pdo_int.h, so they can be used by the drivers. Thoughts? Cheers -- Matteo Beccati Development & Consulting - http://www.beccati.com/