You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@datafusion.apache.org by "findepi (via GitHub)" <gi...@apache.org> on 2024/11/19 12:43:44 UTC
[I] CREATE TABLE succeeds when schema has duplicate names, resulting in a table that cannot be selected from [datafusion]
findepi opened a new issue, #13487:
URL: https://github.com/apache/datafusion/issues/13487
### Describe the bug
CREATE TABLE succeeds when schema has duplicate names, resulting in a table that cannot be selected from
### To Reproduce
```
> CREATE TABLE t AS SELECT * FROM (SELECT 1 AS id, 'Foo' AS name) l JOIN (SELECT 1 AS id, 'Bar' as name) r ON l.id = r.id;
0 row(s) fetched.
Elapsed 0.016 seconds.
> SELECT * FROM t;
Schema error: Schema contains duplicate qualified field name t.id
> SELECT count(*) FROM t;
Schema error: Schema contains duplicate qualified field name t.id
```
### Expected behavior
If `CREATE TABLE` succeeds, the table should be readable.
If the table is not going to be readable (and we know this at create time), the `CREATE TABLE` should fail.
### Additional context
_No response_
--
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-unsubscribe@datafusion.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [I] CREATE TABLE succeeds when schema has duplicate names, resulting in a table that cannot be selected from [datafusion]
Posted by "findepi (via GitHub)" <gi...@apache.org>.
findepi commented on issue #13487:
URL: https://github.com/apache/datafusion/issues/13487#issuecomment-2485614410
take
--
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-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org