xgbtxy opened a new pull request, #3045:
URL: https://github.com/apache/datafusion-sqlparser-rs/pull/3045

   `SELECT * FROM x WHERE a ILIKE ANY pat ESCAPE '!'` currently displays as:
   
   ```sql
   SELECT * FROM x WHERE a ILIKE ANYpat ESCAPE '!'
   ```
   
   Because `Expr::ILike` with `Some(escape_char)` emitted `"ANY"` without a 
trailing space (unlike `Expr::Like` and the non-`ESCAPE` branch of 
`Expr::ILike`), `ANY` concatenates into identifier patterns and changes the 
reparsed AST (`any: true, pattern: pat` -> `any: false, pattern: ANYpat`).
   
   This PR emits `"ANY "` in that branch and adds unit tests plus a fuzz seed.
   
   Verified locally with `cargo test --all-features`, `cargo fmt --all -- 
--check`, and `cargo clippy --all-targets --all-features -- -D warnings`.
   
   AI assistance was used in discovering this round-trip mismatch and drafting 
the fix and tests; all changes were reviewed and verified locally.


-- 
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]

Reply via email to