0

I executed the query like this in razor sql.

SELECT * FROM number_log where phonenumber = '6032969081' and is_active='1' ALLOW FILTERING

Its giving me an error like -

ERROR: No secondary indexes on the restricted columns support the provided operators: 'SELECT * FROM number_log where phonenumber = '6032969081' and is_active='1' ALLOW FILTERING'

can anyone please help me out -

Mohanish
  • 164
  • 1
  • 3
  • 10
  • 2
    Possible duplicate of [cassandra, select via a non primary key](http://stackoverflow.com/questions/29793438/cassandra-select-via-a-non-primary-key) – k4ppa Feb 10 '16 at 09:35
  • 1
    Though secondary indexes are available, it comes with huge performance penalty for the query which you are trying to run. You should model your data according to your query requirement. – undefined_variable Feb 10 '16 at 11:38

2 Answers2

4

Try to add an index on your column....

CREATE INDEX ON <b>table_name</b> (<b>field_name</b>);
Galma88
  • 2,398
  • 6
  • 29
  • 50
0

check this out....It can help you about your issue. http://tonylixu.blogspot.in/2015/04/cassandra-no-secondary-indexes-on.html

Aamir
  • 2,173
  • 1
  • 29
  • 58