sergiimk opened a new issue, #2049: URL: https://github.com/apache/datafusion-sqlparser-rs/issues/2049
Related to: https://github.com/apache/datafusion/issues/17802 Between versions `0.57.0` and `0.58.0` there appears to be a regression that decreased parser tolerance to column names that collide with SQL keywords. Example: ```rust use sqlparser::dialect::GenericDialect; use sqlparser::parser::Parser; fn main() { let dialect = GenericDialect {}; // or AnsiDialect let sql = r#" SELECT 'a' as a, offset FROM my_table "#; let ast = Parser::parse_sql(&dialect, sql).unwrap(); println!("AST: {:#?}", ast); } ``` This works on version `0.57.0`, but fails on `0.58.0` with error: ``` ParserError("Expected: end of statement, found: my_table at Line: 5, Column: 14") ``` These queries work fine, which adds some confusing inconsistency into the mix: ```sql SELECT offset FROM my_table ``` ```sql SELECT offset, 'a' as a FROM my_table ``` -- 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]
