agora inbox for pgsql-sql@postgresql.org
help / color / mirror / Atom feedFrom: Marius Andreiana <marius.andreiana@gmail.com>
To: pgsql-sql@lists.postgresql.org
Subject: parser that could handle "FROM... SELECT..." as well as "SELECT... FROM..."
Date: Tue, 8 Oct 2019 09:12:15 +0300
Message-ID: <CAPUEYuYuJSRE_c_k+uBQReKUDZOMb3niiJ3mPuDP6AFdK_+piw@mail.gmail.com> (raw)
Hello Postgres folks,
After reading
https://jvns.ca/blog/2019/10/03/sql-queries-don-t-start-with-select/
and the discussions at https://news.ycombinator.com/item?id=21150606
I'd also like to write "FROM... SELECT..." instead of "SELECT... FROM...".
Postgres doesn't support this though. Would it be possible to please add
parsing support for this syntax as well?
Somebody mentioned:
Engines don’t run sql directly. They make an AST, make an intermediate
representation of instructions and then execute.
So if it results in same AST, the parser should be flexible.
Thanks!
Marius
view thread (5+ messages) latest in thread
Message-ID: <CAPUEYuYuJSRE_c_k+uBQReKUDZOMb3niiJ3mPuDP6AFdK_+piw@mail.gmail.com>
Permalink: ../CAPUEYuYuJSRE_c_k+uBQReKUDZOMb3niiJ3mPuDP6AFdK_+piw@mail.gmail.com/
Also on: postgresql.org/message-id/CAPUEYuYuJSRE_c_k+uBQReKUDZOMb3niiJ3mPuDP6AFdK_+piw@mail.gmail.com
reply
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-sql@postgresql.org
Cc: marius.andreiana@gmail.com, pgsql-sql@lists.postgresql.org
Subject: Re: parser that could handle "FROM... SELECT..." as well as "SELECT... FROM..."
In-Reply-To: <CAPUEYuYuJSRE_c_k+uBQReKUDZOMb3niiJ3mPuDP6AFdK_+piw@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox