Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1riEVt-00FsRw-Sj for pgsql-hackers@arkaria.postgresql.org; Thu, 07 Mar 2024 14:14:26 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1riEVs-005mOu-Bz for pgsql-hackers@arkaria.postgresql.org; Thu, 07 Mar 2024 14:14:24 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1riEVr-005mNv-3Y for pgsql-hackers@lists.postgresql.org; Thu, 07 Mar 2024 14:14:24 +0000 Received: from fhigh4-smtp.messagingengine.com ([103.168.172.155]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1riEVm-003K1h-Gb for pgsql-hackers@postgresql.org; Thu, 07 Mar 2024 14:14:22 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.47]) by mailfhigh.nyi.internal (Postfix) with ESMTP id BD7BA114014B; Thu, 7 Mar 2024 09:14:17 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute6.internal (MEProxy); Thu, 07 Mar 2024 09:14:17 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t=1709820857; x= 1709907257; bh=WY7Kv7gD6GrzLGKDA7HyMB5z3YsB8GLQe4znGhl0ZO0=; b=V u55WTP0xJE3J3/h2sjjQeCCXf+qv+aEgZer+AAdMdvkDrqwly3u5fBkXIYjGOJEv NFZgwtn842OQEDnXcOx0PFsYY3bqX9w8U1A3Zfxo/NQsBTkv2d0rqrMxmJLtBwpu 5jgTjFu/UZ1KqyAODnM+/WAOwFchmV6NLe0qtLdg5YJbPX6/pyJFOHhRMnjLFbXL p3NIZ90uWwLBCrNYzMFdF2622DTw9r6XdmXTExeyfdsJTOJq2ZTS/XdTyNGJNSxK S9lvej8xPPtL51dGe0D2V61PeTrzemsdki3UfMVgG8LSLlCs8Mh47SMAVc/BVrJ4 VlBImPr3M4CIVrpJQsEWg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrieefgdeiudcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpeffhffvvefukfggtggugfgjsehtkeertddttdejnecuhfhrohhmpeetlhhvrghr ohcujfgvrhhrvghrrgcuoegrlhhvhhgvrhhrvgesrghlvhhhrdhnohdqihhprdhorhhgqe enucggtffrrghtthgvrhhnpeelvdekvdeuleetfeffveejgfefueelheejtdeiveejleff geefleegvdetkedvteenucffohhmrghinhepvghnthgvrhhprhhishgvuggsrdgtohhmpd hpohhsthhgrhdrvghsnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghi lhhfrhhomheprghlvhhhvghrrhgvsegrlhhvhhdrnhhoqdhiphdrohhrgh X-ME-Proxy: Feedback-ID: ia2694551:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 7 Mar 2024 09:14:17 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alvh.no-ip.org; s=schmee; t=1709820855; bh=Q9ykopsyE0bZFhiQggj9qCpc1gtfT6COXHJ5BvSWttQ=; h=Date:From:To:Cc:Subject:In-Reply-To:From; b=EkV59Z3ugZtcB22tV/ic2VC0Hw7/wt1Dg+5p9bhMynGfN8zb5ysDJ/oiUXozhPSrK 4ZZzXQzojDaNhudiKANnMnl2VHqK/6hHIBNY9V/ZnJVgyPCTmAG4CZGxboTGkQYLVl KrPcIDKq6f6CsV8shRhxfzWzTZcjKlXeCz0GqMGXqP8+iGvFwCICTdo8SfiZe8ar0A +K/99kaLdK7AJR3meEfdDnsW5KEb7TCjkqaela61XFR4j0IciH4Ho1SadmyntnvAOo x7S/cdqdFYVz87yP0zdeeJmyBZopV/JE10xhvrf4VjRFXobrMUY3Aps4khkCFm4g11 WQ2KBPjqI0kkA== Received: by schmee.alvh.no-ip.org (Postfix, from userid 1000) id 2013BD84; Thu, 7 Mar 2024 15:14:15 +0100 (CET) Date: Thu, 7 Mar 2024 15:14:15 +0100 From: Alvaro Herrera To: Tomas Vondra Cc: Amit Langote , Erik Rijkers , jian he , Andres Freund , Andrew Dunstan , PostgreSQL-development Subject: Re: remaining sql/json patches Message-ID: <202403071414.mrlp64mw4qex@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 2024-Mar-07, Tomas Vondra wrote: > I was experimenting with the v42 patches, and I think the handling of ON > EMPTY / ON ERROR clauses may need some improvement. Well, the 2023 standard says things like ::= JSON_VALUE [ ] [ ON EMPTY ] [ ON ERROR ] which implies that if you specify it the other way around, it's a syntax error. > I'm not sure what the SQL standard says about this, but it seems other > databases don't agree on the order. Is there a particular reason to > not allow both orderings? I vaguely recall that trying to also support the other ordering leads to having more rules. Now maybe we do want that because of compatibility with other DBMSs, but frankly at this stage I wouldn't bother. -- Álvaro Herrera PostgreSQL Developer — https://www.EnterpriseDB.com/ "I am amazed at [the pgsql-sql] mailing list for the wonderful support, and lack of hesitasion in answering a lost soul's question, I just wished the rest of the mailing list could be like this." (Fotis) https://postgr.es/m/200606261359.k5QDxE2p004593@auth-smtp.hol.gr