dd-annarose commented on issue #17508: URL: https://github.com/apache/datafusion/issues/17508#issuecomment-3559424424
do we want to make it possible for two columns in the output schema to have the same exact qualified name? Postgresql does allow this: `SELECT data.a, CAST(data.a as string) from data;` would yield 2 columns, both named `data.a`. This is not a great feature, and I understand forbidding it. But this [PR](https://github.com/apache/datafusion/pull/3222) aligns DF on the behavior of Posgres & spark > I would also like to match the behavior of Postgres and Spark where CAST does not appear in the field names in the schema I think a first step towards a solution to this issue would either: - making `CAST(B.C as Utf8)` have qualified name ("B", "C") so that the name tracker can detect column `B.C` has an already seen name - OR making it so that unaliased CASTs do appear in the field name in the schema, something like `B.C::TEXT` -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
