cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Benjamin Lerer (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CASSANDRA-10380) SELECT count within a partition does not respect LIMIT
Date Tue, 22 Sep 2015 16:23:04 GMT

    [ https://issues.apache.org/jira/browse/CASSANDRA-10380?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14902897#comment-14902897
] 

Benjamin Lerer commented on CASSANDRA-10380:
--------------------------------------------

I might be wrong but I do not think so. CASSANDRA-7981 is in 2.2.

> SELECT count within a partition does not respect LIMIT
> ------------------------------------------------------
>
>                 Key: CASSANDRA-10380
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-10380
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Core
>            Reporter: Adam Holmberg
>            Assignee: Benjamin Lerer
>            Priority: Minor
>
> {code}
> cassandra@cqlsh> create KEYSPACE test WITH replication = {'class': 'SimpleStrategy',
'replication_factor': '1'};
> cassandra@cqlsh> use test;
> cassandra@cqlsh:test> create table t (k int, c int, v int, primary key (k, c));
> cassandra@cqlsh:test> INSERT INTO t (k, c, v) VALUES (0, 0, 0);
> cassandra@cqlsh:test> INSERT INTO t (k, c, v) VALUES (0, 1, 0);
> cassandra@cqlsh:test> INSERT INTO t (k, c, v) VALUES (0, 2, 0);
> cassandra@cqlsh:test> select * from t where k = 0;
>  k | c | v
> ---+---+---
>  0 | 0 | 0
>  0 | 1 | 0
>  0 | 2 | 0
> (3 rows)
> cassandra@cqlsh:test> select count(*) from t where k = 0 limit 2;
>  count
> -------
>      3
> (1 rows)
> {code}
> Expected: count should return 2, according to limit.
> Actual: count of all rows in partition
> This manifests in 3.0, does not appear in 2.2



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

Mime
View raw message