dcapwell commented on code in PR #4006:
URL: https://github.com/apache/cassandra/pull/4006#discussion_r2010631555


##########
src/java/org/apache/cassandra/cql3/Operation.java:
##########
@@ -374,8 +374,16 @@ public Operation prepare(TableMetadata metadata, 
ColumnMetadata receiver, boolea
         {
             if (!(receiver.type instanceof CollectionType))
             {
-                if (!(receiver.type instanceof CounterColumnType))
-                    throw new InvalidRequestException(String.format("Invalid 
operation (%s) for non counter column %s", toString(receiver), receiver.name));
+                if (canReadExistingState)
+                {
+                    if (!(receiver.type instanceof NumberType<?>))
+                        throw new 
InvalidRequestException(String.format("Invalid operation (%s) for non-numeric 
type %s", toString(receiver), receiver.name));
+                }

Review Comment:
   new feature, `-=` now supports numeric types, just like `+=` does



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: pr-unsubscr...@cassandra.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscr...@cassandra.apache.org
For additional commands, e-mail: pr-h...@cassandra.apache.org

Reply via email to