findepi opened a new pull request, #13489: URL: https://github.com/apache/datafusion/pull/13489
## Which issue does this PR close? - fixes https://github.com/apache/datafusion/issues/13476 - fixes https://github.com/apache/datafusion/issues/13487 - fixes https://github.com/apache/datafusion/issues/6543 ## Rationale for this change In SQL, selecting single column multiple times is legal and most modern databases support this. This commit adds such support to DataFusion too. ## What changes are included in this PR? - allow creation of schemas for duplicated names. DFSchema is used in logical plan to describe output of a relational operator, and In SQL, this is totally valid to have duplicated names - a better long term fix would be to limit Schema use for field resolution during initial query plan building and use unambiguous "symbols" or "variables" in the logical plan. This would fall under https://github.com/apache/datafusion/issues/12723 - add checks for CREATE TABLE and CREATE VIEW to disallow creation of tables with duplicate field names - previously this was taken care of by schema construction checks, but only partially, as witnessed by https://github.com/apache/datafusion/issues/13487 ## Are these changes tested? yes ## Are there any user-facing changes? yes, more valid queries are supported -- 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