Basically here is how my table is set up:
CREATE TABLE points (
name ascii,
id varint,
attributes map<ascii, ascii>,
PRIMARY KEY (name, id)
)
and if I run the following SELECT statement I get this returned:
SELECT id, attributes from points limit 5;
id | attributes
----+------------------------------------------
1 | {STATION/Name: ABC, Type: 2, pFreq: 101}
2 | {STATION/Name: ABC, Type: 1, pFreq: 101}
3 | {STATION/Name: DEF, Type: 1, pFreq: 103}
4 | {STATION/Name: GHI, Type: 2, pFreq: 105}
5 | {STATION/Name: GHI, Type: 1, pFreq: 105}
What I would like to do is be able to form a WHERE clause based on info inside of attributes. Something like the following statement:
SELECT id FROM points WHERE name = 'NAME' AND attributes['pFreq'] = 101;
However, when I run this I get the following error:
Bad Request: line 1:56 no viable alternative at input '['
I looked at this discussion and it seems as though it is not supported yet, is this true? Or is there a way to filter on the attributes information?
Here are the versions I am working with:
[cqlsh 4.1.1 | Cassandra 2.0.7 | CQL spec 3.1.1 | Thrift protocol 19.39.0]