Re: question about where clause of CQL update statement

2012-10-09 Thread Sylvain Lebresne
> Is it not possible to include a column in both the set clause and in the > where clause? No it's not. Or rather in that case what is not supported is the use of secondary indexes in update where clauses. But if 'locked' is indeed not part of your primary key, then at least the error message suc

Re: question about where clause of CQL update statement

2012-10-08 Thread aaron morton
What is the CF schema ? > Is it not possible to include a column in both the set clause and in the > where clause? And if it is not possible, how come? Not sure. Looks like you are looking for a conditional update here. You know the row is at ID 1 and you only want to update if locked = 'fal

question about where clause of CQL update statement

2012-10-05 Thread John Sanda
I am using CQL 3 and trying to execute the following, UPDATE CHANGELOGLOCK SET LOCKED = 'true', LOCKEDBY = '10.11.8.242 (10.11.8.242)', LOCKGRANTED = '2012-10-05 16:58:01' WHERE ID = 1 AND LOCKED = 'false'; It gives me the error, Bad Request: PRIMARY KEY part locked found in SET part. The primar