Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:45704 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 45492 invoked from network); 9 Oct 2009 06:18:20 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 9 Oct 2009 06:18:20 -0000 Authentication-Results: pb1.pair.com header.from=christopher.jones@oracle.com; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=christopher.jones@oracle.com; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain oracle.com from 148.87.113.124 cause and error) X-PHP-List-Original-Sender: christopher.jones@oracle.com X-Host-Fingerprint: 148.87.113.124 rcsinet12.oracle.com Received: from [148.87.113.124] ([148.87.113.124:38165] helo=rgminet12.oracle.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id F3/B0-42384-AA5DECA4 for ; Fri, 09 Oct 2009 02:18:19 -0400 Received: from rgminet13.oracle.com (rcsinet13.oracle.com [148.87.113.125]) by rgminet12.oracle.com (Switch-3.3.1/Switch-3.3.1) with ESMTP id n996HrIR013356 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 9 Oct 2009 06:17:54 GMT Received: from acsmt354.oracle.com (acsmt354.oracle.com [141.146.40.154]) by rgminet13.oracle.com (Switch-3.3.1/Switch-3.3.1) with ESMTP id n98LJxOq005264; Fri, 9 Oct 2009 06:18:44 GMT Received: from abhmt003.oracle.com by acsmt356.oracle.com with ESMTP id 20305686921255069075; Thu, 08 Oct 2009 23:17:55 -0700 Received: from [141.144.160.13] (/141.144.160.13) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Thu, 08 Oct 2009 23:17:55 -0700 Message-ID: <4ACED592.7070807@oracle.com> Date: Thu, 08 Oct 2009 23:17:54 -0700 User-Agent: Thunderbird 2.0.0.23 (X11/20090817) MIME-Version: 1.0 To: Samuel ROZE CC: internals@lists.php.net References: <1255038690.10759.9.camel@samuel-laptop> <4ACE6613.808@oracle.com> <1255067917.4144.4.camel@samuel-laptop> In-Reply-To: <1255067917.4144.4.camel@samuel-laptop> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Source-IP: acsmt354.oracle.com [141.146.40.154] X-Auth-Type: Internal IP X-CT-RefId: str=0001.0A090202.4ACED5A4.00BB:SCFMA4539814,ss=1,fgs=0 Subject: Re: [PHP-DEV] Patch: Use notices in PDO From: christopher.jones@oracle.com (Christopher Jones) Samuel ROZE wrote: > It's a good idea. > > - PDO::NOTICES_FETCH -> PDO::NOTICES_ENABLED > - PDO::NOTICES_NONE -> PDO::NOTICES_DISABLED > > That's better ? That works. > I see that you are from the Oracle team. Can you explain me how oracle > works to raise notices like PostgreSQL ? Or can you build a proof of > concept to get notices from Oracle ? I'm equating your NOTICES to Oracle's DBMS_OUTPUT. See "Getting Output with DBMS_OUTPUT" on p 181 of: http://www.oracle.com/technology/tech/php/underground-php-oracle-manual.html Something similar could be coded in the PDO driver. The amount of text output could be quite large, depending on the user's coding style. Is your design extensible enough to allow for streaming/chunking if the interface needs to be enhanced? PL/SQL also has compile time warnings and errors that are handled differently, see "PL/SQL Success With Information Warnings" on p167. Chris > > Thanks. > Samuel. > > Le jeudi 08 octobre 2009 à 15:22 -0700, Christopher Jones a écrit : >> Samuel ROZE wrote: >>> Hi, >>> >>> I've make a patch which insert notices concepts to PDO. It create: >>> - PDO::noticeInfo() - to be like errorInfo >>> - PDO::ATTR_LOG_NOTICES, the name of the PDO parameter >>> - PDO::NOTICES_FETCH - fetch notices >> I initially took "FETCH" to mean it was related to a query; this >> wouldn't always be the case. What about calling it NOTICES_ENABLE? >> >> Chris >> > > -- Blog: http://blogs.oracle.com/opal Twitter: http://twitter.com/ghrd