cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nitesh Kumar (JIRA)" <>
Subject [jira] [Created] (CASSANDRA-4700) cql 2 query
Date Fri, 21 Sep 2012 21:06:07 GMT
Nitesh Kumar created CASSANDRA-4700:

             Summary: cql 2 query
                 Key: CASSANDRA-4700
             Project: Cassandra
          Issue Type: Bug
          Components: Core
    Affects Versions: 1.2.0 beta 2
         Environment: java
            Reporter: Nitesh Kumar
            Priority: Critical

i was trying to run cql 2 query

cqlsh:stats> UPDATE Minutewise_Product_Stats SET ''=''+1,
''=''+1 WHERE
KEY='2017:4' ;

WHEN I GOT  this error

ERROR 20:38:46,220 Error occurred during processing of message.
    at org.apache.cassandra.cql.UpdateStatement.prepareRowMutations(
    at org.apache.cassandra.cql.UpdateStatement.prepareRowMutations(
    at org.apache.cassandra.cql.QueryProcessor.batchUpdate(
    at org.apache.cassandra.cql.QueryProcessor.processStatement(
    at org.apache.cassandra.cql.QueryProcessor.process(
    at org.apache.cassandra.thrift.CassandraServer.execute_cql_query(
    at org.apache.cassandra.thrift.Cassandra$Processor$execute_cql_query.getResult(
    at org.apache.cassandra.thrift.Cassandra$Processor$execute_cql_query.getResult(
    at org.apache.thrift.ProcessFunction.process(
    at org.apache.thrift.TBaseProcessor.process(
    at org.apache.cassandra.thrift.CustomTThreadPoolServer$
    at java.util.concurrent.ThreadPoolExecutor.runWorker(
    at java.util.concurrent.ThreadPoolExecutor$

attached is the patch file  to fix this bug


diff --git a/src/java/org/apache/cassandra/cql/ b/src/java/org/apache/cassandra/cql/
index 3a47712..0caa61b 100644
--- a/src/java/org/apache/cassandra/cql/
+++ b/src/java/org/apache/cassandra/cql/
@@ -146,8 +146,11 @@ public class UpdateStatement extends AbstractModification
         CFMetaData metadata = validateColumnFamily(keyspace, columnFamily, hasCommutativeOperation);
-        if (hasCommutativeOperation)
-            cLevel.validateCounterForWrite(metadata);
+        if (hasCommutativeOperation){
+        	ConsistencyLevel currentCLevel = getConsistencyLevel();
+        	currentCLevel.validateCounterForWrite(metadata);
+        }
         QueryProcessor.validateKeyAlias(metadata, keyName);

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:

View raw message