Re: parser that could handle "FROM... SELECT..." as well as"SELECT... FROM..." - Mailing list pgsql-sql

From Pavel Stehule
Subject Re: parser that could handle "FROM... SELECT..." as well as"SELECT... FROM..."
Date
Msg-id CAFj8pRCsrM=2=Tz0=PGHntcWFSNV4ig4kxdY4sSRQ0M0t1QVhw@mail.gmail.com
Whole thread Raw
In response to parser that could handle "FROM... SELECT..." as well as "SELECT... FROM..."  (Marius Andreiana <marius.andreiana@gmail.com>)
Responses Re: parser that could handle "FROM... SELECT..." as well as"SELECT... FROM..."
Re: parser that could handle "FROM... SELECT..." as well as "SELECT... FROM..."
List pgsql-sql
Hi

út 8. 10. 2019 v 8:12 odesílatel Marius Andreiana <marius.andreiana@gmail.com> napsal:
Hello Postgres folks,

After reading
I'd also like to write "FROM... SELECT..." instead of "SELECT... FROM...".

This article is little bit strange, it mix syntax and execution together 

Postgres doesn't support this though. Would it be possible to please add parsing support for this syntax as well?

PostgreSQL supports ANSI/SQL.  ANSI/SQL doesn't allow use clauses in any order.

Personally I don't see any benefit of proposed feature - It breaks portability of SQL queries (that is not high today).

Regards

Pavel


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

pgsql-sql by date:

Previous
From: Marius Andreiana
Date:
Subject: parser that could handle "FROM... SELECT..." as well as "SELECT... FROM..."
Next
From: Marius Andreiana
Date:
Subject: Re: parser that could handle "FROM... SELECT..." as well as"SELECT... FROM..."