comphead commented on PR #6566: URL: https://github.com/apache/arrow-datafusion/pull/6566#issuecomment-1618727650
> We have observed that the mismatch problem is not only related to SELECT INTO's. Table creation with CREATE TABLE AS has the same problem while matching the schemas. > > With my last commits, I have changed how the window expressions are named to be used in window executors. Now, window function columns of the batches have the same name as the plans. > > .slt and unit tests are edited accordingly. We now have longer plans and column names, but the problem is solved. To make progress, I think applying this PR and opening another issue that shortens the window names would work better. Thanks @berkaysynnada I will check this today. You right, the problem is related to create mem table and can be reproduced with ``` let sql = "create table t as SELECT SUM(c1) OVER(ORDER BY c1) FROM (select 1 c1)" ``` To make it window aliases shorten this is good idea, I can create a followup issue. I was looking into this for last couple of days and there is mess in `select.rs` for window processing, actually leading DFSchema to fail on shortened names even if they aliased -- 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]
