Using datastax 3.0.
Connected to Test Cluster at localhost:9160.
[cqlsh 2.2.0 | Cassandra 184.108.40.206 | CQL spec 3.0.0 | Thrift protocol 19.33.0]
Use HELP for help.
Using above cql, created a table t0 with composite key (col1, col2, col3)
I am able to do the following :
select * from t0 where col1 = 'abc'
select * from t0 where col2 = 'def'
Querying on 'col3' alone is giving an error.
select * from t0 where col3 = '123'
Bad Request: PRIMARY KEY part col3 cannot be restricted (preceding part col2 is either not restricted or by a non-EQ relation)
Perhaps you meant to use CQL 2? Try using the -2 option when starting cqlsh.
What is the difference between querying on 'col2' alone and 'col3' alone ?
I would have thought querying on 'col2' also should error out.