[CALCITE-2101] Push count(column) using filtered aggregate#586
Closed
b-slim wants to merge 2 commits intoapache:masterfrom
Closed
[CALCITE-2101] Push count(column) using filtered aggregate#586b-slim wants to merge 2 commits intoapache:masterfrom
b-slim wants to merge 2 commits intoapache:masterfrom
Conversation
Contributor
Author
|
@jcamachor this PR is good to review as well but probably will need to adjust test results once we pull in the other fixes |
9de5d56 to
f47b245
Compare
f47b245 to
f275464
Compare
jcamachor
reviewed
Dec 20, 2017
| } | ||
| aggregation = new JsonAggregation("count", name, only); | ||
| if (aggCall.getArgList().size() == 1) { | ||
| final JsonFilter filter = new JsonCompositeFilter(JsonFilter.Type.NOT, |
Contributor
There was a problem hiding this comment.
@b-slim , can we add a comment here explaining what this is doing? It does not seem straightforward unless you understand well how Druid works (specially the JsonSelector(only, null, null))
| // Druid count aggregator can handle 3 scenarios: | ||
| // 1. count(distinct col) when approximate results | ||
| // are acceptable and col is not a metric | ||
| // FYI case exact count(distinct column) is handled using group by and count as well |
Contributor
There was a problem hiding this comment.
Is there a follow-up JIRA for this? If there is not, can we create it? Then we can reference it here.
Contributor
Author
There was a problem hiding this comment.
no am saying that we are handling this case already and the planer already does write it as druid group by.
7mming7
pushed a commit
to Kyligence/calcite
that referenced
this pull request
Jan 23, 2021
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.
Push count(column) using filtered aggregation.
This PR is somehow related to
#585 and #585
Thus would like to get those PR merged first then will adjust the test cases and rebase this one afterward.