LucaCappelletti94 opened a new pull request, #3076: URL: https://github.com/apache/datafusion-sqlparser-rs/pull/3076
`SELECT -(-1) COLLATE BINARY` in the SQLite dialect parses as `-((-1) COLLATE BINARY)`, and `+x COLLATE NOCASE` and `~x COLLATE NOCASE` also put the collation under the operator, while SQLite reads `(-(-1)) COLLATE BINARY`. This PR maps the `UnaryPlusMinus` level from #2829 to just above `Collate` in the SQLite dialect, and adds a `Precedence::UnaryBitwiseNot` level for the operand of `~`, which keeps its current bound in every other dialect. SQLite `~ 1 * 2` now groups as `(~1) * 2`, as in SQLite. In PostgreSQL `~` is a generic prefix operator that groups inside `COLLATE`. -- 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]
