[ 
https://issues.apache.org/jira/browse/CASSANDRA-8216?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Benjamin Lerer resolved CASSANDRA-8216.
---------------------------------------
    Resolution: Invalid

I first thought that the problem was coming from the new {{count}} function but 
in fact the {{count}} function behave properly. The behavior of the old 
function was wrong and the DTest need to be fixed.
The {{LIMIT}} clause is used to limit the number of rows returned to the user 
but count (as well as the other aggregations) returns only one row so limit one 
has no impact on count and 2 is the valid response.

> Select Count with Limit returns wrong value
> -------------------------------------------
>
>                 Key: CASSANDRA-8216
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-8216
>             Project: Cassandra
>          Issue Type: Bug
>            Reporter: Philip Thompson
>            Assignee: Benjamin Lerer
>             Fix For: 3.0
>
>
> The dtest cql_tests.py:TestCQL.select_count_paging_test is failing on trunk 
> HEAD but not 2.1-HEAD.
> The query {code} select count(*) from test where field3 = false limit 1; 
> {code} is returning 2, where obviously it should only return 1 because of the 
> limit. This may end up having the same root cause of #8214, I will be 
> bisecting them both soon.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to