atahanyorganci commented on PR #16023: URL: https://github.com/apache/datafusion/pull/16023#issuecomment-2916493090
Current implementation fails in call to `assert_valid_optimization` where schema of a optimization pass is compared against the previous state. Failure occurs when alias is replaced with an other. For example ```sql SELECT b.id FROM employees a JOIN employees b USING (id) WHERE b.department = 'HR' ``` Since alias `b` won't exist after the optimization it is replaced with `a`. This causes `TableReferences` to not be the same and the invariant fails eventhough both of the alises refer to the same 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: 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