In the above code, when I apply WHERE condition on a SELECT as shown below you can see it returns 0 rows. If I set the secondary key in cqlsh it WORKS.
cqlsh:befit> SELECT * FROM USER WHERE zipcode=75063;
key | email | name | rating1to10 | userid | zipcode
------------+----------------+------------+-------------+--------+---------
0x6a6f686e | john@smith.com | John Smith | 34 | john | 75063
(1 rows)
cqlsh:befit> SELECT * FROM USER WHERE rating1to10=34;
In the above code, when I apply WHERE condition on a SELECT as shown below you can see it returns 0 rows. If I set the secondary key in cqlsh it WORKS.
cqlsh:befit> SELECT * FROM USER WHERE zipcode=75063;
key | email | name | rating1to10 | userid | zipcode ------------+----------------+------------+-------------+--------+--------- 0x6a6f686e | john@smith.com | John Smith | 34 | john | 75063
(1 rows)
cqlsh:befit> SELECT * FROM USER WHERE rating1to10=34;
(0 rows)
Please advise. Thank you