@Stephan: in that case, you can easily tell the names of all columns you
want to retrieve, so you can make a query to retrieve those list of
composite columns.


@Jeremiah,
So where is my best bet ? Should I leave the supercolumns as it is as of
now, since I can find a good way to use them incase I replace them with
composite columns?



On Wed, Jan 4, 2012 at 4:01 AM, Stephen Pope <stephen.p...@quest.com> wrote:

>  The bonus you're talking about here, how do I apply that?
>
>  For example, my columns are in the form of number.id such as 4.steve,
> 4.greg, 5.steve, 5.george. Is there a way to query a slice of numbers with
> a list of ids? As in, I want all the columns with numbers between 4 and 10
> which have ids steve or greg.
>
>  Cheers,
>  Steve
>
> -----Original Message-----
> From: Jeremiah Jordan [mailto:jeremiah.jor...@morningstar.com]
> Sent: Tuesday, January 03, 2012 3:12 PM
> To: user@cassandra.apache.org
> Cc: Asil Klin
> Subject: Re: Replacing supercolumns with composite columns; Getting the
> equivalent of retrieving a list of supercolumns by name
>
> The main issue with replacing super columns with composite columns right
> now is that if you don't know all your sub-column names you can't select
> multiple "super columns" worth of data in the same query without getting
> extra stuff.  You have to use a slice to get all subcolumns of a given
> super column, and you can't have disjoint slices, so if you want two super
> columns full, you have to get all the other stuff that is in between them,
> or make two queries.
> If you know what all of the sub-column names are you can ask for all of
> the super/sub column pairs for all of the super columns you want and not
> get extra data.
>
> If you don't need to pull multiple super columns at a time with slices
> like that, then there isn't really an issue.
>
> A bonus of using composite keys like this, is that if there is a specific
> sub column you want from multiple super columns, you can pull all those out
> with a single multiget and you don't have to pull the rest of the columns...
>
> So there are pros and cons...
>
> -Jeremiah
>
>
> On 01/03/2012 01:58 PM, Asil Klin wrote:
> > I have a super columns family which I always use to retrieve a list of
> > supercolumns(with all subcolumns) by name. I am looking forward to
> > replace all SuperColumns in my schema with the composite columns.
> >
> > How could I design schema so that I could do the equivalent of
> > retrieving a list of supercolumns by name, in case of using composite
> > columns.
> >
> > (As of now I thought of using the supercolumn name as the first
> > component of the composite name and the subcolumn name as 2nd
> > component of composite name.)
>

Reply via email to