Oops, I made a mistake thought I was paging on partition key when I actually was paging on columns. No need of token and columns are ordered. Sorry about bothering the ones who read this, it was a PEBCAK.
Alain 2013/8/21 Alain RODRIGUEZ <arodr...@gmail.com> > Hi, I am sorry about digging this up but I was in search of this kind of > information and read this thread. > > How to make sure that the first rowkey you select has the smaller token ? > I mean when you perform "select rowkey from my_table limit N;" can you have > any data with any token or is data token ordered by default ? > > I tried it in dev and I have data with bigger token, but also with smaller > token so I would have to do : > > select rowkey from my_table where token(rowkey) > > token(last_rowkey_returned) limit N; > > But also : > > select rowkey from my_table where token(rowkey) < > token(last_rowkey_returned) limit N; > > How to make sure you scan all your data, and only once, with CQL3 ? Am I > misunderstanding or missing something ? > > Alain > > 2013/5/14 aaron morton <aa...@thelastpickle.com> > >> select rowkey from my_table limit N; >> while some_row_is_returned do >> select rowkey from my_table where token(rowkey) > >> token(last_rowkey_returned) limit N; >> >> That should work for you. >> >> See >> http://www.datastax.com/docs/1.2/cql_cli/using/paging#non-ordered-partitioner-paging >> >> Cheers >> >> ----------------- >> Aaron Morton >> Freelance Cassandra Consultant >> New Zealand >> >> @aaronmorton >> http://www.thelastpickle.com >> >> On 11/05/2013, at 9:23 AM, Thorsten von Eicken <t...@rightscale.com> >> wrote: >> >> Thanks, this is interesting, but if I'm not mistaken, Astyanax uses CQL2. >> I'm trying to find a CQL3 solution on top the binary protocol. There has to >> be a way to do this in CQL3...? >> Thorsten >> >> >> >> On 5/10/2013 1:33 PM, Keith Wright wrote: >> >> What you are proposing should work and I started to implement that using >> multiple threads over the token ranges but decided instead to use to >> Astyanax's read all rows recipe as it does much of that already. It >> required some work to convert the composite CQL2 format returned from >> Astayanx into what is expected for CQL3 but did work. Here's an outline >> of what you would do: >> >> >> >> >> >