jayzhan211 commented on issue #5492: URL: https://github.com/apache/datafusion/issues/5492#issuecomment-6717279802
@alamb a question on rule 2 of https://github.com/apache/datafusion/issues/5492#issuecomment-6479090126: should an error-instead-of-wrong-result PR also be allowed to reject queries that return correct rows in a released version? I'm not sure that regression is acceptable here, so I'd prefer not to. I'd keep queries that work in the release working, and use an error instead of a semantic fix only for shapes that are wrong in the release or never worked, until the general framework lands. The case: #26874 makes a `LATERAL` with a `HAVING` over an ungrouped aggregate error. That is right for the shapes that are wrong in 55.2.0, but as written it also rejects queries that are correct in 55.2.0: ```sql SELECT t1.id, sub.cnt FROM t1, LATERAL (SELECT count(*) AS cnt FROM t2 HAVING count(*) > t1.id) AS sub; -- 55.2.0, main and DuckDB: (1, 3), (2, 3); #26874: error ``` A narrower condition (error only when decorrelation groups the aggregate by the correlation columns) keeps every wrong-in-55.2.0 case as an error and these queries working. I suggested it in my review of #26874. -- 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]
