[ https://issues.apache.org/jira/browse/PHOENIX-2965?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15317553#comment-15317553 ]
James Taylor commented on PHOENIX-2965: --------------------------------------- bq. It generates a slightly inferior plan, though, in that it aggregate into a single row on the client rather than the server. Would you mind filing a JIRA specifically for this? I think we can do this work post 4.8. bq. In this case it is at least to some extent ... Sounds like a bug, but not sure I understand completely. I think we arbitrarily choose GroupBy.UNGROUPED_GROUP_BY figuring it doesn't matter. But it sounds like you've found a case where it *does*. This would be good to fix for 4.8 IMHO. Thanks for the follow up, [~lhofhansl]! > Use DistinctPrefixFilter logic for COUNT(DISTINCT ...) and COUNT(...) GROUP BY > ------------------------------------------------------------------------------ > > Key: PHOENIX-2965 > URL: https://issues.apache.org/jira/browse/PHOENIX-2965 > Project: Phoenix > Issue Type: Sub-task > Reporter: Lars Hofhansl > Fix For: 4.8.0 > > > Parent uses skip scanning to optimize DISTINCT and certain GROUP BY > operations along the row key. > COUNT queries are optimized differently, could be sped up significantly as > well. > [~giacomotaylor], I might need to help into where COUNT(DISTINCT) queries are > planned and optimized. -- This message was sent by Atlassian JIRA (v6.3.4#6332)