Search code examples
javacassandrathrifthectorkundera

How do I search on Indexed column in Cassandra using Java-Thrift API


I have a column family in Cassandra and on one particular column, I have secondary index defined.

I want to fetch row key for this particular column value. How can I achieve this using plain Thrift API for Java? In Pelops I achieve this by creating IndexClause and calling:

Map <Bytes, List<Column>> qResults = selector.getIndexedColumns(tableName, 
                                                               ix,    
                                                               slicePredicate,
                                                               consistencyLevel);

Solution

  • Please have a look at:

    http://cassandra-user-incubator-apache-org.3065146.n2.nabble.com/Row-iteration-over-indexed-clause-td7368274.html