Re: Sorted Integer -> UUID

2010-12-02 Thread Brandon Williams
On Wed, Dec 1, 2010 at 8:33 AM, Benjamin Waldher wrote: > How can I have a sorted set of rows of Integer -> UUID where the integer > may exist many times? > If you need to repeat an integer as a column name, add entropy and use a BytesType column. Pack your integer in big endian format, and appe

Re: Sorted Integer -> UUID

2010-12-01 Thread Aaron Morton
Could you use a Super CF?Super Col name is the Integer, and the Col Names are the UUID. Not sure what your col values are or your key. There are some limitations to Super CF but I do not think they would apply in this case http://wiki.apache.org/cassandra/CassandraLimitationsYou can the slice the s

Re: Sorted Integer -> UUID

2010-12-01 Thread Daniel Lundin
Unless I misunderstand the Q, composing the column names with the row keys and merging the resulting would yield something useful. keyA => (1, uuid), (2, uuid), (3, uid) keyB => (1, uuid), (2, uuid), (3, uid) Should be transformed into: (1, keyA, uuid), (1, keyB, uuid), (2, keyA, uuid), (2,

Sorted Integer -> UUID

2010-12-01 Thread Benjamin Waldher
I have a fairly simple problem that might require a complicated solution. I need to store Integer -> UUID in a column family, and be able to query (and then paginate) the rows ordered by the integer in descending order. This is simple enough if no two rows have the same integer, as the integer