LucaCappelletti94 opened a new pull request, #2679:
URL: https://github.com/apache/datafusion-sqlparser-rs/pull/2679
`Expr` had three variants for the `IN` predicate, `InList`, `InSubquery` and
`InUnnest`, each repeating the left-hand expression and the `NOT` flag, two of
them repeating ClickHouse's `GLOBAL` flag, and each with its own copy of the
`Display`, `Spanned` and parser code. Supporting another right-hand side, such
as SQLite's `IN table_name`, meant a fourth copy.
They are now one `Expr::In { expr, target, negated, global }`, where
`target` is an `InTarget`: `List`, `Subquery` or `Unnest`. The SQL that parses
and the text printed back are unchanged, `GLOBAL` is still only accepted before
a list or subquery, and `size_of::<Expr>()` stays at 328 bytes. This is a
breaking change for code that builds or matches `Expr::InList`,
`Expr::InSubquery` or `Expr::InUnnest`, which now match `Expr::In` with the
corresponding `InTarget`.
--
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]