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 86DE5107F7 for ; Sat, 13 Apr 2013 11:26:51 +0000 (UTC) Received: (qmail 39335 invoked by uid 500); 13 Apr 2013 11:26:48 -0000 Delivered-To: apmail-cassandra-user-archive@cassandra.apache.org Received: (qmail 39196 invoked by uid 500); 13 Apr 2013 11:26:48 -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 39171 invoked by uid 99); 13 Apr 2013 11:26:47 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 13 Apr 2013 11:26:47 +0000 X-ASF-Spam-Status: No, hits=2.5 required=5.0 tests=FILL_THIS_FORM_SHORT,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of edlinuxguru@gmail.com designates 209.85.212.177 as permitted sender) Received: from [209.85.212.177] (HELO mail-wi0-f177.google.com) (209.85.212.177) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 13 Apr 2013 11:26:42 +0000 Received: by mail-wi0-f177.google.com with SMTP id hm14so302115wib.10 for ; Sat, 13 Apr 2013 04:26:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:content-type; bh=E6LeAQP+lRrln6GcQMLasZIqiMh6kpU5MlaT9+U2jmg=; b=vFQBpBHdhhXGz/G1YLifAdb27cTyU49RkevpIatLgs3uWzh9BgSyq0GARx8vIFzUJ4 ENTQmmgNjBHedPZm5Nrkqv8OrrkkKErKI8URT//yuwg6S6Z+1D+i3sI/7VolrzFmPooZ rvPhZ9b7mQhPDW7zICs0KZVNY+5PkcyVDwMkbdZyrYotyHag+T9AkrTDiKbi3dgeLMvC 7s1p6ZbKtG2QhosGXdDkkh0KEL4xCZMP0Uc2je24JJgRFQ6kXDmFdAf7LlU9imqPm/Lu kkSBRwE+B0lph50pyDdERqpAiyyasHL4TMFy6QHuL+ID6h8JMK/r79WUVTLByGgwl+Gc 2WlA== MIME-Version: 1.0 X-Received: by 10.180.87.193 with SMTP id ba1mr2812839wib.10.1365852381304; Sat, 13 Apr 2013 04:26:21 -0700 (PDT) Received: by 10.194.61.137 with HTTP; Sat, 13 Apr 2013 04:26:21 -0700 (PDT) In-Reply-To: References: Date: Sat, 13 Apr 2013 07:26:21 -0400 Message-ID: Subject: Re: Anyway To Query Just The Partition Key? From: Edward Capriolo To: "user@cassandra.apache.org" Content-Type: multipart/alternative; boundary=f46d0444813100de7e04da3c4aab X-Virus-Checked: Checked by ClamAV on apache.org --f46d0444813100de7e04da3c4aab Content-Type: text/plain; charset=ISO-8859-1 You can 'list' or 'select *' the column family and you get them in a pseudo random order. When you say subset it implies you might want a specific range which is something this schema can not do. On Sat, Apr 13, 2013 at 2:05 AM, Gareth Collins wrote: > Hello, > > If I have a cql3 table like this (I don't have a table with this data - > this is just for example): > > create table ( > surname text, > city text, > country text, > event_id timeuuid, > data text, > PRIMARY KEY ((surname, city, country),event_id)); > > there is no way of (easily) getting the set (or a subset) of partition > keys, is there (i.e. surname/city/country)? If I want easy access to do > queries to get a subset of the partition keys, I have to create another > table? > > I am assuming yes but just making sure I am not missing something obvious > here. > > thanks in advance, > Gareth > --f46d0444813100de7e04da3c4aab Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
You can 'list' or 'select *' the column fa= mily and you get them in a pseudo random order. When you say subset it impl= ies you might want a specific range which is something this schema can not = do.




On Sat, Apr 13, 2013 at 2:05 AM, Gareth Collins <gareth.o.collin= s@gmail.com> wrote:
Hello,

I= f I have a cql3 table like this (I don't have a table with this data - = this is just for example):

create table (
=A0 =A0 surname text,
=A0 =A0 city text,
=A0 =A0 country text,
=A0 =A0 e= vent_id timeuuid,
=A0 =A0 data text,
=A0 =A0 PRIMARY KE= Y ((surname, city, country),event_id));

there is no way of (easily) getting the set (or a subset) of partition= keys, is there (i.e. surname/city/country)? If I want easy access to do qu= eries to get a subset of the partition keys, I have to create another table= ?

I am assuming yes but just making sure I am not missing= something obvious here.

thanks in advance,
<= div>Gareth

--f46d0444813100de7e04da3c4aab--