I’m using Cassandra 1.1.0 with CQL 3.0.
When create table, the following error occurs.
I referred to http://www.datastax.com/dev/blog/cql3-evolutions
cqlsh:test> CREATE TABLE timeseries (
... event_type text,
... insertion_time timestamp,
... event blob,
... PRIMARY KEY (event_type, insertion_time)
... ) WITH CLUSTERING ORDER BY insertion_time DESC;
Bad Request: line 6:22 mismatched input 'ORDER' expecting '='
Is this invalid query?
Do you have any suggestions?
Thanks.
The
WITH CLUSTERING ORDERsyntax was only added in Cassandra 1.1.1 (just released a few days ago), so it won’t work in 1.1.0.Also, though, that example is missing some parentheses around the clustering definition. You want:
Hope that helps. I’ll let the author of that article know about the problem.