fix(prqlc, append): apply column order on CTEs too#5323
Conversation
|
thanks @Fanaen — I haven't gone through the whole thing to compare, but it looks like a reasonable approach do you know why the tests are failing here? same issue as the prior PR? we can skip sqlite tests if the tradeoff is better support for the main dialects |
|
Thanks @max-sixty! Yeah, no need to compare. This attempt is very different, and I think a lot better. All the extra baggage of the previous attempts would have been detrimental to the readability of this one, hence the new PR. I'll scrap the other one. I'll keep that in mind! Yep, same tests, same issues: only this time, the SQL results are good! This fix should be fully dialect independent. I wanted integration tests with different table sources, and I did not see that the table columns were not matching in some dialects. This should be easy to fix. I'll look into that tomorrow. |
9566268 to
270b83c
Compare
|
We're good to go! There is one issue I encountered while working on this. When there is a |
|
nice, thanks a lot @Fanaen ! |
This is my third attempt to solve the issue of
appendpositional mapping.It enables the workaround for #2680
Problem
UNIONneed the same number of column and in both queriesQuery Resultstab in the playground:Solution
This fix operate in anchoring stage only.
There's two parts: