cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tyler Patterson (JIRA)" <>
Subject [jira] [Created] (CASSANDRA-4612) cql error with ORDER BY when using IN
Date Tue, 04 Sep 2012 18:21:08 GMT
Tyler Patterson created CASSANDRA-4612:

             Summary: cql error with ORDER BY when using IN
                 Key: CASSANDRA-4612
             Project: Cassandra
          Issue Type: Bug
         Environment: ubuntu, cassandra trunk (commit 769fe895a36868c47101f681f5fdd721bee1ad62
            Reporter: Tyler Patterson
            Assignee: Pavel Yaskevich

            CREATE TABLE test(
                my_id varchar, 
                col1 int, 
                value varchar, 
                PRIMARY KEY (my_id, col1)

INSERT INTO test(my_id, col1, value) VALUES ( 'key1', 1, 'a');
INSERT INTO test(my_id, col1, value) VALUES ( 'key2', 3, 'c');
INSERT INTO test(my_id, col1, value) VALUES ( 'key3', 2, 'b');
INSERT INTO test(my_id, col1, value) VALUES ( 'key4', 4, 'd');
SELECT col1 FROM test WHERE my_id in('key1', 'key2', 'key3') ORDER BY col1;

The following error results: TSocket read 0 bytes
The log gives a traceback:
ERROR [Thrift:8] 2012-09-04 12:02:15,894 (line 202) Error occurred
during processing of message.
java.lang.IndexOutOfBoundsException: Index: 1, Size: 1
	at java.util.ArrayList.RangeCheck(
	at java.util.ArrayList.get(
	at org.apache.cassandra.cql3.statements.SelectStatement$
	at org.apache.cassandra.cql3.statements.SelectStatement$
	at java.util.Arrays.mergeSort(
	at java.util.Arrays.sort(
	at java.util.Collections.sort(
	at org.apache.cassandra.cql3.statements.SelectStatement.orderResults(
	at org.apache.cassandra.cql3.statements.SelectStatement.process(
	at org.apache.cassandra.cql3.statements.SelectStatement.executeInternal(
	at org.apache.cassandra.cql3.statements.SelectStatement.execute(
	at org.apache.cassandra.cql3.statements.SelectStatement.execute(
	at org.apache.cassandra.cql3.QueryProcessor.processStatement(
	at org.apache.cassandra.cql3.QueryProcessor.process(
	at org.apache.cassandra.thrift.CassandraServer.execute_cql_query(
	at org.apache.cassandra.thrift.Cassandra$Processor$execute_cql_query.getResult(
	at org.apache.cassandra.thrift.Cassandra$Processor$execute_cql_query.getResult(
	at org.apache.thrift.ProcessFunction.process(
	at org.apache.thrift.TBaseProcessor.process(
	at org.apache.cassandra.thrift.CustomTThreadPoolServer$
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(
	at java.util.concurrent.ThreadPoolExecutor$

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message