[CALCITE-1288] Avoid doing the same join twice if count(distinct) exists#247
Closed
gparai wants to merge 1 commit intoapache:masterfrom
Closed
[CALCITE-1288] Avoid doing the same join twice if count(distinct) exists#247gparai wants to merge 1 commit intoapache:masterfrom
gparai wants to merge 1 commit intoapache:masterfrom
Conversation
| .build(); | ||
| checkPlanning(program, "select emp.empno, count(*), avg(distinct dept.deptno) \n" | ||
| + " from sales.emp emp inner join sales.dept dept \n" | ||
| + " on emp.deptno = dept.deptno \n" |
Contributor
There was a problem hiding this comment.
Can you remove the spaces before the line feeds? they are unncessary, but they turn into spaces at the ends of lines in RelOptRulesTest.xml which somebody's editor will mysteriously remove at some point in the future.
julianhyde
pushed a commit
to julianhyde/calcite
that referenced
this pull request
Jun 15, 2016
…sts (Gautam Parai) Close apache#247
7cb85db to
cf9e6bb
Compare
c1554e1 to
81081a5
Compare
More cosmetic changes
ldming
pushed a commit
to ldming/mycalcite
that referenced
this pull request
Sep 13, 2018
… aggregate functions (Gautam Parai) Close apache/calcite#247
jamesstarr
pushed a commit
to jamesstarr/calcite
that referenced
this pull request
Mar 16, 2026
apache#262) …le (apache#247) * Add an utility class named SqlTypeMappingRules that defines some utilities to build type mappings; * Add an interface named SqlTypeMappingRule for all the type mapping rules; * Add SqlTypeCoercionRule that defines the type coercion rules, add doc about how to customize new rules; * Rename SqlTypeAssignmentRules to SqlTypeAssignmentRule; * SqlTypeAssignmentRule now only defines rules of type assignment; * Add a new method SqlValidator.setSqlTypeCoercionRules to set up custom type coercion rules. Co-authored-by: yuzhao.cyz <yuzhao.cyz@gmail.com>
jamesstarr
pushed a commit
to jamesstarr/calcite
that referenced
this pull request
Mar 16, 2026
apache#262) …le (apache#247) * Add an utility class named SqlTypeMappingRules that defines some utilities to build type mappings; * Add an interface named SqlTypeMappingRule for all the type mapping rules; * Add SqlTypeCoercionRule that defines the type coercion rules, add doc about how to customize new rules; * Rename SqlTypeAssignmentRules to SqlTypeAssignmentRule; * SqlTypeAssignmentRule now only defines rules of type assignment; * Add a new method SqlValidator.setSqlTypeCoercionRules to set up custom type coercion rules. Co-authored-by: yuzhao.cyz <yuzhao.cyz@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change will allow AggregateExpandDistictAggregatesRule JOIN instance to generates multi-phases aggregates when we see a query with one distinct and one or more non-distinct aggregates