Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:96544 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 74809 invoked from network); 21 Oct 2016 21:33:36 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 21 Oct 2016 21:33:36 -0000 Authentication-Results: pb1.pair.com smtp.mail=adam.baratz@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=adambaratz@php.net; sender-id=unknown Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.214.53 as permitted sender) X-PHP-List-Original-Sender: adam.baratz@gmail.com X-Host-Fingerprint: 209.85.214.53 mail-it0-f53.google.com Received: from [209.85.214.53] ([209.85.214.53:38865] helo=mail-it0-f53.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 0D/06-28528-FA98A085 for ; Fri, 21 Oct 2016 17:33:35 -0400 Received: by mail-it0-f53.google.com with SMTP id 66so9515434itl.1 for ; Fri, 21 Oct 2016 14:33:35 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=GvCxcwBrh53Vdq+cOmNekG8NNqIr+9A+Qzafi7jKtJ4=; b=D4rqQ/LKr34m9Wr//kfulmORzbqCfGftiNctsyAg3pjlSpI6v4uz3ZuDnysoQevtYP jMO6NzAHPsdiFvhC5VS8rE4lXnlLiflohpQJUOFuImIIiADXRxlfMfCgZnCKMd+K2HaD JEyGEQ6Fc37aZxh5931QDybZRSaWWKj7tbTkPI4Tlc5PuKUhNaJmg/cQlnz/nF51+E8f NeOccecfYBMMfLekn2PdYy+Vngm1eJsPhM2JVKOjbksZTa2794lWYjEZ1Ydjeu+BY+mw tb7fH790bRI4ee7jSi3Vy/EBJ25nXAUiG8y9iy/PIVLyiZTg+mgS4mBsxfs0WChlwEXI 3MXg== X-Gm-Message-State: ABUngvd/5fz0LzB/MOemUA52BtqdrcX7ae9fRUwXjl/nbfhj8obSx7i+NdJdpihosll6gw== X-Received: by 10.36.66.208 with SMTP id i199mr589023itb.86.1477085609154; Fri, 21 Oct 2016 14:33:29 -0700 (PDT) Received: from mail-it0-f54.google.com (mail-it0-f54.google.com. [209.85.214.54]) by smtp.gmail.com with ESMTPSA id 80sm2700947iot.36.2016.10.21.14.33.29 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 21 Oct 2016 14:33:29 -0700 (PDT) Received: by mail-it0-f54.google.com with SMTP id e187so9108223itc.1 for ; Fri, 21 Oct 2016 14:33:29 -0700 (PDT) X-Received: by 10.36.123.135 with SMTP id q129mr2961510itc.117.1477085605701; Fri, 21 Oct 2016 14:33:25 -0700 (PDT) MIME-Version: 1.0 Received: by 10.64.158.164 with HTTP; Fri, 21 Oct 2016 14:33:25 -0700 (PDT) In-Reply-To: <361d013f-8a8c-c91a-1b4f-b2baad92fac2@lsces.co.uk> References: <361d013f-8a8c-c91a-1b4f-b2baad92fac2@lsces.co.uk> Date: Fri, 21 Oct 2016 17:33:25 -0400 X-Gmail-Original-Message-ID: Message-ID: To: Lester Caine Cc: PHP internals Content-Type: multipart/alternative; boundary=001a1146ec86d4b3cf053f66ca63 Subject: Re: [PHP-DEV] [RFC] Driver-Specific PDO Param Types From: adambaratz@php.net (Adam Baratz) --001a1146ec86d4b3cf053f66ca63 Content-Type: text/plain; charset=UTF-8 On Wed, Oct 19, 2016 at 12:25 PM, Lester Caine wrote: > On 18/10/16 23:05, Adam Baratz wrote: > > Please share your feedback. I'm happy to hear thoughts about the > pdo_dblib > > example, but the RFC is more about the possibility of driver-specific > types > > than these particular ones. > > The whole point of PDO was that anything that was not available across > ALL drivers would be emulated in some way, or flagged in a way that does > not break code, so nothing should be added specifically targeting a > particular driver if it will cause problems when someone selects a > different driver to run the same application. > I'm starting to think I'm looking at the problem in too narrow a way. Other supported databases have these column types and likely have these issues. I'm going to read the PDO code some more and look at the ADOdb type system[1]. It might be there should be common types for binary and unicode params, and probably also double params. I'm adding doubles, because it looks like there's an issue where, since really_register_bound_param() converts doubles to strings, drivers will bind them as strings and not doubles. Even though, for example, the MySQL driver attempts to distinguish between strings and doubles. I'll follow up when I've gathered more information, but this may be in the form of a separate RFC. Thanks, Adam --- [1] http://adodb.org/dokuwiki/doku.php?id=v5:dictionary:dictiona ry_index#summary_of_types --001a1146ec86d4b3cf053f66ca63--