[jira] [Commented] (CASSANDRA-5230) cql3 doesn't support multiple clauses on primary key components

2013-04-11 Thread Olivier LHeureux (JIRA)

[ 
https://issues.apache.org/jira/browse/CASSANDRA-5230?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13629262#comment-13629262
 ] 

Olivier LHeureux commented on CASSANDRA-5230:
-

If I add another key like:

CREATE TABLE foo (
  key text,
  c text,
  d text,
  v text,
  PRIMARY KEY (key, c, d)
);

select c from foo where key = 'foo' and c in ('1', '2') will still result in a 
Bad Request error.

Is this the expected behavior?

 cql3 doesn't support multiple clauses on primary key components
 ---

 Key: CASSANDRA-5230
 URL: https://issues.apache.org/jira/browse/CASSANDRA-5230
 Project: Cassandra
  Issue Type: Bug
  Components: Core
Affects Versions: 1.2.0
Reporter: Brandon Williams
Assignee: Sylvain Lebresne
 Fix For: 1.2.2

 Attachments: 5230.patch


 In trying to write a dtest for CASSANDRA-5225, I noticed that given a table 
 such as:
 {noformat}
 CREATE TABLE foo (
   key text,
   c text,
   v text,
   PRIMARY KEY (key, c)
 )
 {noformat}
 It is possible to slice the values of 1 or 2 for c:
 {noformat}
 select c from foo where key = 'foo' and c  '0' and c  '3';
 {noformat}
 However, there is no way to get these explicitly by name, even though it 
 should be possible:
 {noformat}
 cqlsh:Keyspace1 select c from foo where key = 'foo' and c in ('1', '2');
 Bad Request: PRIMARY KEY part c cannot be restricted by IN relation
 {noformat}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (CASSANDRA-5230) cql3 doesn't support multiple clauses on primary key components

2013-04-11 Thread Aleksey Yeschenko (JIRA)

[ 
https://issues.apache.org/jira/browse/CASSANDRA-5230?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13629306#comment-13629306
 ] 

Aleksey Yeschenko commented on CASSANDRA-5230:
--

bq. Is this the expected behavior?

Yes, only the last part of the key can be restricted by IN. In your case it's 
'd'.

 cql3 doesn't support multiple clauses on primary key components
 ---

 Key: CASSANDRA-5230
 URL: https://issues.apache.org/jira/browse/CASSANDRA-5230
 Project: Cassandra
  Issue Type: Bug
  Components: Core
Affects Versions: 1.2.0
Reporter: Brandon Williams
Assignee: Sylvain Lebresne
 Fix For: 1.2.2

 Attachments: 5230.patch


 In trying to write a dtest for CASSANDRA-5225, I noticed that given a table 
 such as:
 {noformat}
 CREATE TABLE foo (
   key text,
   c text,
   v text,
   PRIMARY KEY (key, c)
 )
 {noformat}
 It is possible to slice the values of 1 or 2 for c:
 {noformat}
 select c from foo where key = 'foo' and c  '0' and c  '3';
 {noformat}
 However, there is no way to get these explicitly by name, even though it 
 should be possible:
 {noformat}
 cqlsh:Keyspace1 select c from foo where key = 'foo' and c in ('1', '2');
 Bad Request: PRIMARY KEY part c cannot be restricted by IN relation
 {noformat}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (CASSANDRA-5230) cql3 doesn't support multiple clauses on primary key components

2013-02-20 Thread Jonathan Ellis (JIRA)

[ 
https://issues.apache.org/jira/browse/CASSANDRA-5230?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13582171#comment-13582171
 ] 

Jonathan Ellis commented on CASSANDRA-5230:
---

+1

 cql3 doesn't support multiple clauses on primary key components
 ---

 Key: CASSANDRA-5230
 URL: https://issues.apache.org/jira/browse/CASSANDRA-5230
 Project: Cassandra
  Issue Type: Bug
  Components: Core
Affects Versions: 1.2.0
Reporter: Brandon Williams
Assignee: Sylvain Lebresne
 Fix For: 1.2.2

 Attachments: 5230.patch


 In trying to write a dtest for CASSANDRA-5225, I noticed that given a table 
 such as:
 {noformat}
 CREATE TABLE foo (
   key text,
   c text,
   v text,
   PRIMARY KEY (key, c)
 )
 {noformat}
 It is possible to slice the values of 1 or 2 for c:
 {noformat}
 select c from foo where key = 'foo' and c  '0' and c  '3';
 {noformat}
 However, there is no way to get these explicitly by name, even though it 
 should be possible:
 {noformat}
 cqlsh:Keyspace1 select c from foo where key = 'foo' and c in ('1', '2');
 Bad Request: PRIMARY KEY part c cannot be restricted by IN relation
 {noformat}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira