ygf11 commented on issue #4478:
URL:
https://github.com/apache/arrow-datafusion/issues/4478#issuecomment-1334964872
Yes, cast expression is ignored in the column name.
I think the other reason is our projection does not support duplicated items
which seems PostgreSQL and spark both support.
### spark ###
```sql
spark-sql> select 1,1,1,1,1;
1 1 1 1 1
1 1 1 1 1
Time taken: 0.337 seconds, Fetched 1 row(s)
```
### PostgreSQL ###
```sql
> select 1,1,1,1;
?column? | ?column? | ?column? | ?column?
----------+----------+----------+----------
1 | 1 | 1 | 1
(1 row)
```
### datafusion ###
```sql
❯ select 1, 1, 1, 1;
Plan("Projections require unique expression names but the expression
\"Int64(1)\" at position 0 and \"Int64(1)\" at position 1 have the same name.
Consider aliasing (\"AS\") one of them.")
```
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]