mvzink opened a new pull request, #2172:
URL: https://github.com/apache/datafusion-sqlparser-rs/pull/2172
Adds support for MySQL-specific `SELECT` modifiers that appear after the
`SELECT` keyword. Grammar from the [docs]:
```sql
SELECT
[ALL | DISTINCT | DISTINCTROW ]
[HIGH_PRIORITY]
[STRAIGHT_JOIN]
[SQL_SMALL_RESULT] [SQL_BIG_RESULT] [SQL_BUFFER_RESULT]
[SQL_NO_CACHE] [SQL_CALC_FOUND_ROWS]
select_expr [, select_expr] ...
```
Manual testing shows that these options can appear in any order relative to
each other, so for the sake of fidelity, we parse this separately from how we
parse distinct and other options for other dialects, in a new
`Parser::parse_select_modifiers` method.
`DISTINCTROW` is a legacy (but not deprecated) synonym for `DISTINCT`, so it
just gets canonicalized as `DISTINCT`.
[docs]: https://dev.mysql.com/doc/refman/8.4/en/select.html
--
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]