From: Aleksander Alekseev <a.alekseev@postgrespro.ru>
To: Andres Freund <andres@anarazel.de>
Cc: Pavel Stehule <pavel.stehule@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Arcadiy Ivanov <arcadiy@gmail.com>
Cc: PostgreSQL Hackers <pgsql-hackers@postgresql.org>
Subject: Re: Parser extensions (maybe for 10?)
Date: Tue, 19 Apr 2016 17:52:43 +0300
Message-ID: <20160419175243.14365e0a@fujitsu> (raw)
In-Reply-To: <20160419140709.7m3euiexqnhmca2s@alap3.anarazel.de>
References: <570C7B5A.9070309@gmail.com>
<5688.1460437831@sss.pgh.pa.us>
<CAFj8pRA6hAG3kg+iANEad+7b+u_Y-Pqnaz-q0TbwBX4h=5h_Yw@mail.gmail.com>
<20160418182523.3f70ad88@fujitsu>
<CAFj8pRCgwN1drV0V7EWQC8eacYbF091nGpG7BGpQFaFG1mY1xg@mail.gmail.com>
<20160418184458.51f203ab@fujitsu>
<CAFj8pRAYQ_Zg6W5ia1RE7vCcOwT3XdKr0OiRoHCEfq1Vb6sycw@mail.gmail.com>
<20160419122003.731704b2@fujitsu>
<20160419140709.7m3euiexqnhmca2s@alap3.anarazel.de>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
> On 2016-04-19 12:20:03 +0300, Aleksander Alekseev wrote:
> > Can we guarantee that extensions don't conflict? In fact we can
> > since we already do it. If all tests pass there is no conflict.
>
> How does that follow? Even if you were to test all possible extensions
> together - obviously not possible - how do passing tests prove the
> grammar to be conflict free?
Do we currently test that all existing extensions work together? No.
And in fact it doesn't matter whether they work together or not. What
matters that concrete subset of extensions chosen by given user work
together. We don't guarantee that extensions are bug free either. In
fact I'm quite sure there are many bugs in PostgreSQL extensions and
PostgreSQL itself. But if `make check` pass probably extension doesn't
have more bugs than usual. Why syntax extension should suddenly be an
exception of these rules?
Also I would like to remind that suggested approach is only about
syntax sugar. The resulting desugared query would be the same as usual.
If it's invalid we just discard it.
For the record - I'm not telling that this SQL extending feature should
necessarily be implemented. Frankly I'm personally quite against it.
I can't think of any real cases when it would be very useful and I don't
think that this feature is worth an effort, not mentioning further
support. All I'm telling is that it could be done using methods that are
well-known for decades.
--
Best regards,
Aleksander Alekseev
http://eax.me/
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: a.alekseev@postgrespro.ru, andres@anarazel.de, pavel.stehule@gmail.com, tgl@sss.pgh.pa.us, arcadiy@gmail.com
Subject: Re: Parser extensions (maybe for 10?)
In-Reply-To: <20160419175243.14365e0a@fujitsu>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox