Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:118099 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 64405 invoked from network); 27 Jun 2022 04:59:45 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 27 Jun 2022 04:59:45 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 2FE3A1804C6 for ; Sun, 26 Jun 2022 23:50:26 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,HTML_MESSAGE, NICE_REPLY_A,RCVD_IN_DNSWL_LOW,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS34011 80.237.132.0/24 X-Spam-Virus: No X-Envelope-From: Received: from wp160.webpack.hosteurope.de (wp160.webpack.hosteurope.de [80.237.132.167]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Sun, 26 Jun 2022 23:50:25 -0700 (PDT) Received: from [176.95.78.98] (helo=[192.168.2.28]); authenticated by wp160.webpack.hosteurope.de running ExIM with esmtpsa (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) id 1o5iZj-0003iS-M6; Mon, 27 Jun 2022 08:50:23 +0200 Content-Type: multipart/alternative; boundary="------------ri3BHmQlZn9pZtblp5TBdxO5" Message-ID: Date: Mon, 27 Jun 2022 08:50:23 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Content-Language: en-US To: internals@lists.php.net References: In-Reply-To: X-bounce-key: webpack.hosteurope.de;marc@mabe.berlin;1656312626;482409b0; X-HE-SMSGID: 1o5iZj-0003iS-M6 Subject: Re: [PHP-DEV] [RFC] [Under Discussion] PDO driver specific sub-classes From: marc@mabe.berlin (Marc Bennewitz) --------------ri3BHmQlZn9pZtblp5TBdxO5 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 21.06.22 01:01, Dan Ackroyd wrote: > Hi, > > Following previous discussions, here is an RFC to have DB specific > classes for PDO. > > https://wiki.php.net/rfc/pdo_driver_specific_subclasses Hi Dan, Thanks for your RFC! I do have some recommendations for it: 1. It would be great if driver specific constants would be added to the driver specific sub-classes without the driver name repeated in the const name. The counterparts living directly on PDO could be deprecated (later). > PDO::SQLITE_DETERMINISTIC (int) |*> *|*|PDO::MYSQL_ATTR_USE_BUFFERED_QUERY |*(int|*)*| > etc. 2. Another annoying PDO feature is the configurable behavior of exceptions. As now exceptions are the default way it would be nice to not all disabling exceptions if instantiated the new way. > Create all DB sub-classes? yes please > PQescapeIdentifier I think these should be a general PDO method but as we already have `quote` it would be preferable to name it `quoteIdentifier` or how would you explain the difference between `quote` and `escapeIdentifier`? Thanks Marc > cheers > Dan > Ack > --------------ri3BHmQlZn9pZtblp5TBdxO5--