xiedeyantu commented on PR #4209: URL: https://github.com/apache/calcite/pull/4209#issuecomment-2681653583
> According to the description provided by Jira, we need to add a Distinct at the top level of the Project, and perhaps we can also add test cases to JdbcTest to ensure that our transformation implementation is correct. The SQL example: > > ``` > select * from (values (1, 2), (1, 2), (3, 4), (5, 7)) as t(a, b) > intersect > select * from (values (1, 2), (3, 4), (5, 6)) as t(a, b) ; > ``` > > You will know why we need the Distinct. @NobiGo I know the cause of the problem. I considered distinct in the rule, but the field I chose was too special. It was the primary key of the table, so agg was automatically removed. I modified the test case again, making all the current test cases use non-primary keys, and then adding a test case using the primary key field. -- 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]
