blerer commented on code in PR #3507:
URL: https://github.com/apache/cassandra/pull/3507#discussion_r1741046462
##########
src/java/org/apache/cassandra/cql3/restrictions/SimpleRestriction.java:
##########
@@ -327,8 +327,11 @@ public void addToRowFilter(RowFilter filter, IndexRegistry
indexRegistry, QueryO
{
case SINGLE_COLUMN:
List<ByteBuffer> buffers = bindAndGet(options);
- if (operator == Operator.IN || operator == Operator.BETWEEN)
+ if (operator.kind() == Operator.Kind.TERNARY ||
operator.kind() == Operator.Kind.MULTI_VALUE)
{
+ // For BETWEEN we support like in SQL reversed bounds
+ if (operator.kind() == Operator.Kind.TERNARY)
Review Comment:
The sort is always required because we support like in SQL between with
reversed bounds. For example `BETWEEN 1 AND 2` and `BETWEEN 2 AND 1` are both
valid and will return the same rows.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]