incubator-cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul van Hoven <paul.van.ho...@googlemail.com>
Subject CQL : Date comparison in where clause fails
Date Sat, 02 Feb 2013 23:36:58 GMT
I've got a table that has a column called date. I created an index on
the column date with the following command:

CREATE INDEX date_key ON ola (date);

Now, I can perform the following command:

select * from ola where date = '2013-01-01' limit 10;

The results are correctly displayed.

But the the following command fails:
cqlsh:demodb> select * from ola where date > '2013-01-01' limit 10;
Bad Request: No indexed columns present in by-columns clause with Equal operator
Perhaps you meant to use CQL 2? Try using the -2 option when starting cqlsh.

The same happens when using
cqlsh:demodb> select * from ola where date >= '2013-01-01' limit 10;
Bad Request: No indexed columns present in by-columns clause with Equal operator
Perhaps you meant to use CQL 2? Try using the -2 option when starting cqlsh.

Why does this happen?

Mime
View raw message