Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:100043 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 18316 invoked from network); 26 Jul 2017 12:42:12 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 26 Jul 2017 12:42:12 -0000 Authentication-Results: pb1.pair.com header.from=rowan.collins@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=rowan.collins@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 74.125.82.46 as permitted sender) X-PHP-List-Original-Sender: rowan.collins@gmail.com X-Host-Fingerprint: 74.125.82.46 mail-wm0-f46.google.com Received: from [74.125.82.46] ([74.125.82.46:38324] helo=mail-wm0-f46.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id A1/55-49004-32E88795 for ; Wed, 26 Jul 2017 08:42:11 -0400 Received: by mail-wm0-f46.google.com with SMTP id m85so66440413wma.1 for ; Wed, 26 Jul 2017 05:42:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:user-agent:in-reply-to:references:mime-version :content-transfer-encoding:subject:to:from:message-id; bh=NsfWXFN4G1GRnd+IP7IYTspSmgGnLFrPQ1XC5t+tPWA=; b=OnBRZ+v3kAnkMs1U7fIAMkvo/FvD8R2S5yPIOWJ8Yp8KK3xh/KmEKNv13pKSpkJAHI WrhiHxOIav27QF49uBGv6z8L5dV8lX2nGM9gWvv/wo94x9D7mHMkqRPhXeclcWc6Hjd/ +UL4A4MukqJYgAsfbExgOVNS/vRI3Dmm9Dm2CvmPRsLQoRIjiTuNQwKNlIrV6DrCiVA4 AJ8VAKGtuFgMdgGlc5fmUakCsLRNKBI4Ek834Np0zLglqDJ9AfW7XJ5s4dxsG3zbszJn eKcItFZbK0GdZskG0GWQwQ7OOCkXXeB1t/U/aHEmT+Bdh4RIEmLFAX7tS7zC98YvHQci jbYg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:user-agent:in-reply-to:references :mime-version:content-transfer-encoding:subject:to:from:message-id; bh=NsfWXFN4G1GRnd+IP7IYTspSmgGnLFrPQ1XC5t+tPWA=; b=je0TGB/85zN/CAAApSsDDaDTc69H6dEDED6HE/J44mH8MrcMo0yKHmFDGmssjKF1pj Q4gR+GGEdVEiTKPj5k338l1cBxl8tW/dJRRfIGl7ENTYef1eOnItGbk2x3yti3AUQJ34 taphBYLgVFT8n7qrBgLATh4baOZkn8V/VbMFkMVI+NIQc3ABQGOG6N2itU+UKQgMB7yM SynuYUH4fVzk8yz6x7i7S9d1GxILYEhX6vAhBSkmKehyyGo+36twok+0dZlMSXmkWtRn 44qlpJpF55I/VvA+3Zf9IYpxXbwXU112xA4s1gLaY8ACYYdOGmBxis1Tia4u2F2B841r lhbQ== X-Gm-Message-State: AIVw111DFdVim/BFTmKbf4iXFyy24uqqHg3L1Ema80scN9EN8icU8jJf /Lee8wP7yt7kTi9rx10= X-Received: by 10.28.236.219 with SMTP id h88mr607031wmi.143.1501072928589; Wed, 26 Jul 2017 05:42:08 -0700 (PDT) Received: from [10.60.142.110] (188.29.165.81.threembb.co.uk. [188.29.165.81]) by smtp.gmail.com with ESMTPSA id t14sm17916060wra.44.2017.07.26.05.42.06 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 26 Jul 2017 05:42:07 -0700 (PDT) Date: Wed, 26 Jul 2017 13:42:05 +0100 User-Agent: K-9 Mail for Android In-Reply-To: <6B.63.49004.FFD68795@pb1.pair.com> References: <6B.63.49004.FFD68795@pb1.pair.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable To: internals@lists.php.net,=?UTF-8?Q?Micha=C5=82?= Message-ID: Subject: Re: [PHP-DEV] PDO native JSON / array support From: rowan.collins@gmail.com (Rowan Collins) On 26 July 2017 11:25:00 BST, "Micha=C5=82" wrote: >Most database systems have now native support for JSON format=2E Some of= =20 >them, like PostgreSQL, also accepts arrays=2E I rememeber there was some= =20 >fork of pgsql extension with native array support=2E > >Maybe it is time to extend PDO so it can accept at least one of these=20 >formats? What do You think? Hi, What would "support" exactly mean for a JSON type? Since JSON is a way of = serialising data into a string, wouldn't all JSON values going into and out= of the database just look like strings to the driver? For Postgres's array types, some support for serialising and unserialising= would definitely be useful, though, because the format is rather complex, = particularly if you have multidimensional and sparse arrays=2E Obviously, u= sers now have the workaround of transferring as JSON, but I know my last co= mpany had a pair of utility functions to attempt this in userland, which we= re known to be buggy in certain edge cases=2E Regards, --=20 Rowan Collins [IMSoP]