mirror of
https://github.com/apache/datafusion-sqlparser-rs.git
synced 2025-12-11 14:49:35 +00:00
Support UNION/EXCEPT/INTERSECT
This commit is contained in:
parent
533775c0da
commit
52e0f55b6f
6 changed files with 147 additions and 10 deletions
|
|
@ -716,8 +716,7 @@ pub const ALL_KEYWORDS: &'static [&'static str] = &[
|
|||
/// can be parsed unambiguously without looking ahead.
|
||||
pub const RESERVED_FOR_TABLE_ALIAS: &'static [&'static str] = &[
|
||||
// Reserved as both a table and a column alias:
|
||||
WITH, SELECT, WHERE, GROUP, ORDER,
|
||||
// TODO add these with tests: UNION, EXCEPT, INTERSECT,
|
||||
WITH, SELECT, WHERE, GROUP, ORDER, UNION, EXCEPT, INTERSECT,
|
||||
// Reserved only as a table alias in the `FROM`/`JOIN` clauses:
|
||||
ON, JOIN, INNER, CROSS, FULL, LEFT, RIGHT, NATURAL, USING,
|
||||
];
|
||||
|
|
@ -726,8 +725,7 @@ pub const RESERVED_FOR_TABLE_ALIAS: &'static [&'static str] = &[
|
|||
/// can be parsed unambiguously without looking ahead.
|
||||
pub const RESERVED_FOR_COLUMN_ALIAS: &'static [&'static str] = &[
|
||||
// Reserved as both a table and a column alias:
|
||||
WITH, SELECT, WHERE, GROUP, ORDER,
|
||||
// TODO add these with tests: UNION, EXCEPT, INTERSECT,
|
||||
WITH, SELECT, WHERE, GROUP, ORDER, UNION, EXCEPT, INTERSECT,
|
||||
// Reserved only as a column alias in the `SELECT` clause:
|
||||
FROM,
|
||||
];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue