Return-Path: X-Original-To: apmail-cassandra-user-archive@www.apache.org Delivered-To: apmail-cassandra-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 989EE98EB for ; Tue, 3 Jan 2012 22:32:14 +0000 (UTC) Received: (qmail 68658 invoked by uid 500); 3 Jan 2012 22:32:12 -0000 Delivered-To: apmail-cassandra-user-archive@cassandra.apache.org Received: (qmail 68578 invoked by uid 500); 3 Jan 2012 22:32:12 -0000 Mailing-List: contact user-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@cassandra.apache.org Delivered-To: mailing list user@cassandra.apache.org Received: (qmail 68570 invoked by uid 99); 3 Jan 2012 22:32:12 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Jan 2012 22:32:12 +0000 X-ASF-Spam-Status: No, hits=-2.3 required=5.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of Stephen.Pope@quest.com designates 12.106.87.94 as permitted sender) Received: from [12.106.87.94] (HELO alvetxw02.quest.com) (12.106.87.94) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Jan 2012 22:32:05 +0000 Received: from ALVHTXW03.prod.quest.corp (10.1.135.19) by alvetxw02.quest.com (10.1.100.94) with Microsoft SMTP Server (TLS) id 14.1.255.0; Tue, 3 Jan 2012 14:20:47 -0800 Received: from ALVMBXW01.prod.quest.corp ([fe80::48dd:e065:86b3:9cee]) by ALVHTXW03.prod.quest.corp ([::1]) with mapi id 14.01.0255.000; Tue, 3 Jan 2012 14:31:43 -0800 From: Stephen Pope 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 Thread-Topic: Replacing supercolumns with composite columns; Getting the equivalent of retrieving a list of supercolumns by name Thread-Index: AQHMylIXxhPXs3RNWU+UsufWRdMTIJX7mVOA//+f3BA= Date: Tue, 3 Jan 2012 22:31:42 +0000 Message-ID: <654A67E918314D418D96AC894A5B0F0D105960@ALVMBXW01.prod.quest.corp> References: <4F036107.1040600@morningstar.com> In-Reply-To: <4F036107.1040600@morningstar.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.4.60.53] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Virus-Checked: Checked by ClamAV on apache.org 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.gr= eg, 5.steve, 5.george. Is there a way to query a slice of numbers with a li= st of ids? As in, I want all the columns with numbers between 4 and 10 whic= h have ids steve or greg. Cheers, Steve -----Original Message----- From: Jeremiah Jordan [mailto:jeremiah.jordan@morningstar.com]=20 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 equ= ivalent of retrieving a list of supercolumns by name The main issue with replacing super columns with composite columns right no= w is that if you don't know all your sub-column names you can't select mult= iple "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 colu= mn, and you can't have disjoint slices, so if you want two super columns fu= ll, you have to get all the other stuff that is in between them, or make tw= o 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 e= xtra 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 s= ub 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=20 > supercolumns(with all subcolumns) by name. I am looking forward to=20 > replace all SuperColumns in my schema with the composite columns. > > How could I design schema so that I could do the equivalent of=20 > retrieving a list of supercolumns by name, in case of using composite=20 > columns. > > (As of now I thought of using the supercolumn name as the first=20 > component of the composite name and the subcolumn name as 2nd=20 > component of composite name.)