andygrove commented on a change in pull request #7833:
URL: https://github.com/apache/arrow/pull/7833#discussion_r460523985
##########
File path: rust/datafusion/src/execution/context.rs
##########
@@ -140,10 +142,10 @@ impl ExecutionContext {
/// Creates a logical plan
pub fn create_logical_plan(&mut self, sql: &str) -> Result<LogicalPlan> {
- let ast = DFParser::parse_sql(sql)?;
+ let statements = DFParser::parse_sql(sql)?;
- match ast {
- DFASTNode::ANSI(ansi) => {
+ match &statements[0] {
Review comment:
I think we should return an `Err` result here if `statements.len() != 1`.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]