Re: CQL query throws TombstoneOverwhelmingException against a LeveledCompactionStrategy table

2014-10-06 Thread dlu66061
BTW, I am using Cassandra 2.0.6. Is this the same as CASSANDRA-6654 (Droppable tombstones are not being removed from LCS table despite being above 20%) ? I checked my table in JConsole and the droppable tombstone ratio of over 60%. If it is

Re: CQL query regarding indexes

2014-06-13 Thread Akash Pandey
Use senttime as part of primary key CREATE TABLE services.messagepayload_by_date ( record_date timestamp partition_id uuid, messageid bigint, senttime timestamp, PRIMARY KEY (record_date, senttime ) ) Partition id itself should be chronological say a date. Then you put partition id in yo

Re: CQL query regarding indexes

2014-06-12 Thread Jabbar Azam
In this use case you don't need the secondary index. Instead use Primary key(partition_id, senttime) Thanks Jabbar Azam On 12 Jun 2014 23:44, "Roshan" wrote: > Hi > > Cassandra - 2.0.8 > DataStax driver - 2.0.2 > > I have create a keyspace and a table with indexes like below. > CREATE TABLE ser

Re: CQL query regarding indexes

2014-06-12 Thread Bulat Shakirzyanov
As far as I can tell, the problem is that you're not using a partition key in your query. AFAIK, you always have to use partition key in where clause. And ALLOW FILTERING option is to let cassandra filter data from the rows it found using the partition key. One way to solve it is to make partition

Re: cql query

2013-05-04 Thread Sri Ramya
thanks for ur reply. On Fri, May 3, 2013 at 11:45 PM, Jabbar Azam wrote: > Sorry Sri, I've never used hector. How ever it's straightforward in > astyanax. There are examples on the github page. > On 3 May 2013 18:50, "Sri Ramya" wrote: > >> Can you tell me how to do this in hector. Can you gi

Re: cql query

2013-05-03 Thread Jabbar Azam
Sorry Sri, I've never used hector. How ever it's straightforward in astyanax. There are examples on the github page. On 3 May 2013 18:50, "Sri Ramya" wrote: > Can you tell me how to do this in hector. Can you give me some example. > > On Fri, May 3, 2013 at 10:29 AM, Sri Ramya wrote: > >> than

Re: cql query

2013-05-03 Thread Sri Ramya
Can you tell me how to do this in hector. Can you give me some example. On Fri, May 3, 2013 at 10:29 AM, Sri Ramya wrote: > thank you very much. i will try and let you know whether its working or not > > > > On Thu, May 2, 2013 at 7:04 PM, Jabbar Azam wrote: > >> Hello Sri, >> >> As far as I kn

Re: cql query

2013-05-02 Thread Sri Ramya
thank you very much. i will try and let you know whether its working or not On Thu, May 2, 2013 at 7:04 PM, Jabbar Azam wrote: > Hello Sri, > > As far as I know you can if name and age are part of your partition key > and timestamp is the cluster key e.g. > > create table columnfamily ( > n

Re: cql query

2013-05-02 Thread Jabbar Azam
Hello Sri, As far as I know you can if name and age are part of your partition key and timestamp is the cluster key e.g. create table columnfamily ( name varchar, age varchar, tstamp timestamp, partition key((name, age), tstamp) ); Thanks Jabbar Azam On 2 May 2013 11:45, Sri

Re: cql query not giving any result.

2013-03-18 Thread Sylvain Lebresne
> If this is the case, Why can't we restrict "key" as a keyword and not to > be used as a column name? This is only a problem when upgrading from thrift to CQL. Forbidding "key" as a column name in thrift would be weird to say the least. What could be done is that CQL could, when it picks the def

Re: cql query not giving any result.

2013-03-18 Thread Vivek Mishra
If this is the case, Why can't we restrict "key" as a keyword and not to be used as a column name? -Vivek On Mon, Mar 18, 2013 at 2:37 PM, Sylvain Lebresne wrote: > CQL can't work correctly if 2 (CQL) columns have the same name. Now, to > allow upgrade from thrift, CQL does use some default name

Re: cql query not giving any result.

2013-03-18 Thread Sylvain Lebresne
CQL can't work correctly if 2 (CQL) columns have the same name. Now, to allow upgrade from thrift, CQL does use some default names like "key" for the Row key when there isn't anything else. Honestly I think the easiest workaround here is probably to disambiguate things manually. Typically, you cou

Re: cql query not giving any result.

2013-03-15 Thread Vivek Mishra
Any suggestions? -Vivek On Fri, Mar 15, 2013 at 5:20 PM, Vivek Mishra wrote: > Ok. So it's a case when, CQL returns rowkey value as "key" and there is > also column present with name as "key". > > Sounds like a bug? > > -Vivek > > > On Fri, Mar 15, 2013 at 5:17 PM, Kuldeep Mishra > wrote: > >>

Re: cql query not giving any result.

2013-03-15 Thread Vivek Mishra
Ok. So it's a case when, CQL returns rowkey value as "key" and there is also column present with name as "key". Sounds like a bug? -Vivek On Fri, Mar 15, 2013 at 5:17 PM, Kuldeep Mishra wrote: > Hi Sylvain, > I created it using thrift client, here is column family creation > script, > >

Re: cql query not giving any result.

2013-03-15 Thread Kuldeep Mishra
Hi Sylvain, I created it using thrift client, here is column family creation script, Cassandra.Client client; CfDef user_Def = new CfDef(); user_Def.name = "DOCTOR"; user_Def.keyspace = "KunderaExamples"; user_Def.setComparator_type("UTF8Type");

Re: cql query not giving any result.

2013-03-15 Thread Sylvain Lebresne
On Fri, Mar 15, 2013 at 11:43 AM, Kuldeep Mishra wrote: > Hi, > Is it possible in Cassandra to make multiple column with same name ?, like > in this particular scenario I have two column with same name as "key", > first one is rowkey and second on is column name . > > No, it shouldn't be possible

Re: cql query not giving any result.

2013-03-15 Thread Jason Wee
Here is a list of keywords and whether or not the words are reserved. A reserved keyword cannot be used as an identifier unless you enclose the word in double quotation marks. Non-reserved keywords have a specific meaning in certain context but can be used as an identifier outside this context. ht

Re: cql query not giving any result.

2013-03-15 Thread Kuldeep Mishra
Hi, Is it possible in Cassandra to make multiple column with same name ?, like in this particular scenario I have two column with same name as "key", first one is rowkey and second on is column name . Thanks and Regards Kuldeep On Fri, Mar 15, 2013 at 4:05 PM, Kuldeep Mishra wrote: > > Hi , >

Re: CQL query issue

2013-03-05 Thread Sylvain Lebresne
This is not an issue of Cassandra. In particular http://cassandra.apache.org/doc/cql3/CQL.html#selectStmt is up to date. It is an issue of the datastax documentation however. I'll see with them that this gets resolved. On Tue, Mar 5, 2013 at 3:26 PM, Vivek Mishra wrote: > Somebody in group, ple

Re: CQL query issue

2013-03-05 Thread Vivek Mishra
Somebody in group, please confirm if it is an issue or that needs rectified for select syntax. -Vivek On Tue, Mar 5, 2013 at 5:31 PM, Vivek Mishra wrote: > Thank you i am able to solve this one. > If i am trying as : > > SELECT * FROM "CompositeUser" WHERE "userId"='mevivs' LIMIT 100 ALLOW > F

Re: CQL query issue

2013-03-05 Thread Vivek Mishra
Thank you i am able to solve this one. If i am trying as : SELECT * FROM "CompositeUser" WHERE "userId"='mevivs' LIMIT 100 ALLOW FILTERING it works. Somehow got confused by http://www.datastax.com/docs/1.2/cql_cli/cql/SELECT, which states as : SELECT select_expression FROM *keyspace_name.*tab

Re: CQL query issue when fetching data from Cassandra

2012-02-16 Thread aaron morton
> 1). The "IN" operator is not working > SELECT * FROM TestCF WHERE status IN ('Failed', 'Success') IN is only valid for filtering on the row KEY http://www.datastax.com/docs/1.0/references/cql/SELECT e.g. it generates this error using cqlsh cqlsh:dev> SELECT * FROM TestCF WHERE status IN ('Fa

Re: CQL query issue when fetching data from Cassandra

2012-02-16 Thread R. Verlangen
I'm not sure about your first 2 questions. The third might be an exception: check your Cassandra logs. About the "like"-thing: there's no such query possibiliy in Cassandra / CQL. You can take a look at Hadoop / Hive to tackle those problems. 2012/2/16 Roshan > Hi > > I am using Cassandra 1.0.

RE: CQL query using 'OR' in WHERE clause

2011-08-16 Thread Deeter, Derek
- From: Jonathan Ellis [mailto:jbel...@gmail.com] Sent: Monday, August 15, 2011 7:37 PM To: user@cassandra.apache.org Subject: Re: CQL query using 'OR' in WHERE clause Disjunctions are not yet supported and probably will not be until after 1.0. On Mon, Aug 15, 2011 at 6:45 PM, Deeter, De

Re: CQL query using 'OR' in WHERE clause

2011-08-15 Thread Jonathan Ellis
Disjunctions are not yet supported and probably will not be until after 1.0. On Mon, Aug 15, 2011 at 6:45 PM, Deeter, Derek wrote: > Hi, > > We are using CQL to obtain data from Cassandra 0.8.1 using Hector and > getting an error when using ‘OR’ on a secondary index.  I get the same error > when