LucaCappelletti94 opened a new pull request, #3026: URL: https://github.com/apache/datafusion-sqlparser-rs/pull/3026
`SELECT a COLLATE NOCASE COLLATE RTRIM FROM t` fails with `Expected: end of statement, found: RTRIM` in every dialect except PostgreSQL, and a stacked `COLLATE` in an `ORDER BY` or `CREATE INDEX` key fails the same way. SQLite, PostgreSQL and MySQL all accept it. This PR gives `COLLATE` a default precedence just below `::`, which is where PostgreSQL places it, so every dialect reads it as a postfix operator and the one-off check goes away. The new `Precedence::Collate` variant breaks dialects outside the crate that match `Precedence` exhaustively. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
