Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CALCITE-4402] The equalsDeep returns wrong result #2264

Closed
wants to merge 3 commits into from
Closed

[CALCITE-4402] The equalsDeep returns wrong result #2264

wants to merge 3 commits into from

Conversation

hqx871
Copy link

@hqx871 hqx871 commented Nov 16, 2020

The method equalsDeep of SqlCall will returns wrong result when used to compare count and count_distinct, because it does not compare the functionQuantifier

vlsi and others added 2 commits November 15, 2020 13:53
The method equalsDeep of SqlCall will returns wrong result when used to compare count and count_distinct, because it does not compare the functionQuantifier
@@ -146,6 +146,9 @@ public int operandCount() {
return litmus.fail("{} != {}", this, node);
}
SqlCall that = (SqlCall) node;
if (!equalDeep(this.getFunctionQuantifier(), that.getFunctionQuantifier(), litmus)) {
return litmus.fail("{} != {}", this, node);
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix, can you also add test case there.

@danny0405
Copy link
Contributor

danny0405 commented Nov 16, 2020

Can you also log an issue here: https://issues.apache.org/jira/projects/CALCITE/issues/CALCITE-4263?filter=allopenissues,

Your commit message should be with format: [CALCITE-{issue number}] {Your title} ({your GitHub account}).

@chunweilei
Copy link
Contributor

Thank you for your fix. You can find more about how to contribute in https://calcite.apache.org/develop/#contributing.

@hqx871 hqx871 changed the title fix: the equalsDeep returns wrong result [CALCITE-4402] fix: the equalsDeep returns wrong result Nov 16, 2020
@hqx871 hqx871 changed the title [CALCITE-4402] fix: the equalsDeep returns wrong result [CALCITE-4402] The equalsDeep returns wrong result Nov 16, 2020
@hqx871
Copy link
Author

hqx871 commented Nov 16, 2020

Your commit message should be with format: [CALCITE-{issue number}] {Your title} ({your GitHub account}).

Thank you for your fix. You can find more about how to contribute in https://calcite.apache.org/develop/#contributing.

Thanks.

@@ -30,6 +30,10 @@ The [Apache Calcite PMC]({{ site.baseurl }})
is pleased to announce
[Apache Calcite release 1.26.0]({{ site.baseurl }}/docs/history.html#v1-26-0).

**Warning:** Calcite 1.26.0 has **severe** issues with `RexNode` simplification caused by `SEARCH operator` (
wrong data from query optimization, `NullPointerException`), so use 1.26.0 for development only,
and beware that Calcite 1.26.0 would corrupt your data.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unnecessary change.

Copy link
Author

@hqx871 hqx871 Nov 17, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This may be from another contributor

Following [CALCITE-4364], fix the plan diff of TpcdsTest
@hqx871 hqx871 closed this Nov 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants