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 432476F3F for ; Thu, 16 Jun 2011 16:03:35 +0000 (UTC) Received: (qmail 40041 invoked by uid 500); 16 Jun 2011 16:03:32 -0000 Delivered-To: apmail-cassandra-user-archive@cassandra.apache.org Received: (qmail 40010 invoked by uid 500); 16 Jun 2011 16:03:32 -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 40002 invoked by uid 99); 16 Jun 2011 16:03:32 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 16 Jun 2011 16:03:32 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,RFC_ABUSE_POST,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of jbellis@gmail.com designates 74.125.82.172 as permitted sender) Received: from [74.125.82.172] (HELO mail-wy0-f172.google.com) (74.125.82.172) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 16 Jun 2011 16:03:26 +0000 Received: by wyb29 with SMTP id 29so1325174wyb.31 for ; Thu, 16 Jun 2011 09:03:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:from:date :message-id:subject:to:content-type:content-transfer-encoding; bh=dfdpP6wopcqjGZh0YCKEvuPl5pNWiLpje1DdKRv0zbE=; b=EMKi8WAdRzdIeacU5VxuEx8xAy8lomfDkE7ouJ/lcer6Fg964a7QsIxu5O5WArd8PO v7kqPaM45ESlOJEKcZkIUWQe2e6v/+oZHSMqQh1ntZZMx1j2RG61StOScVKEZjMRiE0g ImwFLEK83miufBeVDfht4pT1xJyR7mkAmyH34= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type:content-transfer-encoding; b=XP/NbHmhZa1PluHCx6yHC5MSgW5s+oktFGvL5yUj6A3DUbyk44Ku1R1wM9kVkzKmBN opX5YrfC/irVSEM0GamtO3VJPbRE/rzMTHNQBg5xVkgwa97l0cVDW8AEgTLJUB3Ge6iw GSljWMXdRNbYOt9R2WYVma+9zhEqYSeYO8yGI= Received: by 10.216.68.6 with SMTP id k6mr1101626wed.85.1308240185270; Thu, 16 Jun 2011 09:03:05 -0700 (PDT) MIME-Version: 1.0 Received: by 10.216.89.70 with HTTP; Thu, 16 Jun 2011 09:02:45 -0700 (PDT) In-Reply-To: References: From: Jonathan Ellis Date: Thu, 16 Jun 2011 09:02:45 -0700 Message-ID: Subject: Re: Unable to access column family in CLI after building CF in CQL To: user@cassandra.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org If you create CFs outside the cli, you may need to restart it to refresh its internal cache of the schema. On Thu, Jun 16, 2011 at 8:51 AM, yikes bigdata wr= ote: > Hi, > I was following the CQL example on the DataStax website and was able to > create a new column family and query it. But when I viewed the column fam= ily > in the CLI, it gives me the following error. > # Unable to read column family created from CQL > [default@store] list users2; > users2 not found in current keyspace. > Also, when I try to query the user table from CQL, i'm unable to filter o= n a > key. =A0The user table was created in the CLI but accessible by CQL with = a > simple select * from users; > cqlsh> select * from users where key=3D'tyler'; > Bad Request: cannot parse 'tyler' as hex bytes > > > > > # In the CLI, the store keyspaces displays two column families . > [default@store] show keyspaces; > Keyspace: store: > =A0 Replication Strategy: org.apache.cassandra.locator.SimpleStrategy > =A0 =A0 Options: [replication_factor:1] > =A0 Column Families: > =A0 =A0=A0ColumnFamily: users > =A0 =A0 =A0 Key Validation Class: org.apache.cassandra.db.marshal.BytesTy= pe > =A0 =A0 =A0 Default column value validator: > org.apache.cassandra.db.marshal.BytesType > =A0 =A0 =A0 Columns sorted by: org.apache.cassandra.db.marshal.AsciiType > =A0 =A0 =A0 Row cache size / save period in seconds: 0.0/0 > =A0 =A0 =A0 Key cache size / save period in seconds: 200000.0/14400 > =A0 =A0 =A0 Memtable thresholds: 0.26718749999999997/57/1440 (millions of > ops/MB/minutes) > =A0 =A0 =A0 GC grace seconds: 864000 > =A0 =A0 =A0 Compaction min/max thresholds: 4/32 > =A0 =A0 =A0 Read repair chance: 1.0 > =A0 =A0 =A0 Replicate on write: false > =A0 =A0 =A0 Built indexes: [] > =A0 =A0 =A0 Column Metadata: > =A0 =A0 =A0 =A0 Column Name: email > =A0 =A0 =A0 =A0 =A0 Validation Class: org.apache.cassandra.db.marshal.UTF= 8Type > =A0 =A0 =A0 =A0 Column Name: userName > =A0 =A0 =A0 =A0 =A0 Validation Class: org.apache.cassandra.db.marshal.UTF= 8Type > =A0 =A0=A0ColumnFamily: users2 > =A0 =A0 =A0 Key Validation Class: org.apache.cassandra.db.marshal.UTF8Typ= e > =A0 =A0 =A0 Default column value validator: > org.apache.cassandra.db.marshal.UTF8Type > =A0 =A0 =A0 Columns sorted by: org.apache.cassandra.db.marshal.UTF8Type > =A0 =A0 =A0 Row cache size / save period in seconds: 0.0/0 > =A0 =A0 =A0 Key cache size / save period in seconds: 200000.0/14400 > =A0 =A0 =A0 Memtable thresholds: 0.26718749999999997/57/1440 (millions of > ops/MB/minutes) > =A0 =A0 =A0 GC grace seconds: 864000 > =A0 =A0 =A0 Compaction min/max thresholds: 4/32 > =A0 =A0 =A0 Read repair chance: 1.0 > =A0 =A0 =A0 Replicate on write: true > =A0 =A0 =A0 Built indexes: [] > =A0 =A0 =A0 Column Metadata: > =A0 =A0 =A0 =A0 Column Name: session_token > =A0 =A0 =A0 =A0 =A0 Validation Class: org.apache.cassandra.db.marshal.UTF= 8Type > =A0 =A0 =A0 =A0 Column Name: state > =A0 =A0 =A0 =A0 =A0 Validation Class: org.apache.cassandra.db.marshal.UTF= 8Type > =A0 =A0 =A0 =A0 Column Name: password > =A0 =A0 =A0 =A0 =A0 Validation Class: org.apache.cassandra.db.marshal.UTF= 8Type > =A0 =A0 =A0 =A0 Column Name: birth_year > =A0 =A0 =A0 =A0 =A0 Validation Class: org.apache.cassandra.db.marshal.Lon= gType > =A0 =A0 =A0 =A0 Column Name: gender > =A0 =A0 =A0 =A0 =A0 Validation Class: org.apache.cassandra.db.marshal.UTF= 8Type > Keyspace: system: > Able to see the list of keys generate within the CLI > [default@store] list users; > Using default limit of 100 > ------------------- > RowKey: foo > =3D> (column=3Dage, value=3D3339, timestamp=3D1308182349595000) > =3D> (column=3Demail, value=3Dfoo@email.com, timestamp=3D1308182349594000= ) > =3D> (column=3DuserName, value=3Dfoo, timestamp=3D1308182349591000) > ------------------- > RowKey: bar > =3D> (column=3Demail, value=3Dbar@email.com, timestamp=3D1308182355297000= ) > =3D> (column=3Dgender, value=3D66, timestamp=3D1308182355299000) > =3D> (column=3DuserName, value=3Dbar, timestamp=3D1308182355295000) > ------------------- > RowKey: tyler > =3D> (column=3Demail, value=3Dtyler@email.com, timestamp=3D13081823553030= 00) > =3D> (column=3Dsports, value=3D6261736562616c6c, timestamp=3D130818235530= 9000) > =3D> (column=3DuserName, value=3Dtyler, timestamp=3D1308182355302000) > --=20 Jonathan Ellis Project Chair, Apache Cassandra co-founder of DataStax, the source for professional Cassandra support http://www.datastax.com