Cassandra API equivalent of "SELECT ... FROM ... WHERE id IN ('...', '...', '...');"
Posted
by knorv
on Stack Overflow
See other posts from Stack Overflow
or by knorv
Published on 2010-03-15T08:45:09Z
Indexed on
2010/03/15
8:49 UTC
Read the original article
Hit count: 428
Assume the following data set:
id age city phone
== === ==== =====
alfred 30 london 3281283
jeff 43 sydney 2342734
joe 29 tokyo 1283881
kelly 54 new york 2394929
molly 20 london 1823881
rob 39 sydney 4928381
To get the following result set ..
id age phone
== === =====
alfred 30 3281283
joe 29 1283881
molly 20 1823881
.. using SQL one would issue ..
SELECT id, age, phone FROM dataset WHERE id IN ('alfred', 'joe', 'molly');
What is the corresponding Cassandra API call that would yield the same result set in one command?
© Stack Overflow or respective owner