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


##########
test/distributed/org/apache/cassandra/distributed/test/cql3/SingleNodeTableWalkTest.java:
##########
@@ -421,6 +430,39 @@ protected List<CreateIndexDDL.Indexer> supportedIndexers()
         return state.command(rs, select, annotation);
     }
 
+    public Property.Command<State, Void, ?> likeQuery(RandomSource rs, State 
state)
+    {
+        Symbol symbol = rs.pick(state.searchableTextColumns);
+        TreeMap<ByteBuffer, List<BytesPartitionState.PrimaryKey>> universe = 
state.model.index(symbol);
+
+        NavigableSet<ByteBuffer> allowed = 
Sets.filter(universe.navigableKeySet(),
+                                                      b -> 
!ByteBufferUtil.EMPTY_BYTE_BUFFER.equals(b));
+
+        if (allowed.isEmpty())
+            return Property.ignoreCommand();
+
+        ByteBuffer value = rs.pickOrderedSet(allowed);
+        String valueStr = symbol.type().getString(value);
+        String pattern;
+
+        if (rs.nextBoolean())

Review Comment:
   Pure `%x%` (CONTAINS) and `no-wildcard` exact (MATCHES) are not directly 
produced.  Is there a reason?



-- 
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]

Reply via email to