vegarsti commented on issue #14436: URL: https://github.com/apache/datafusion/issues/14436#issuecomment-3131087119
`DFParser::parse_sql(query)` returns an `Ok` for both examples in the OP 🤔 Did something change in the meantime or am I missing something? My test is ``` #[test] fn test_ambiguous_with_diagnostic() -> Result<()> { // let query = "SELECT * FROM users a, users a"; let query = "WITH cte AS (SELECT 1 AS col), cte AS (SELECT 2 AS col) SELECT 1"; let spans = get_spans(query); match DFParser::parse_sql(query) { Ok(stmts) => { panic!("expected error, got {:?}", stmts); } Err(err) => match err.diagnostic() { Some(diag) => { let diag = diag.clone(); assert_snapshot!(diag.message, @"TODO"); Ok(()) } None => { panic!("expected diagnostic") } }, } } ``` -- 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: github-unsubscr...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org