Opened https://issues.apache.org/jira/browse/CASSANDRA-13105 because it does seem like this should work.
On Wed, Jan 4, 2017 at 5:53 PM, Voytek Jarnot <voytek.jar...@gmail.com> wrote: > Seeing queries return 0 rows incorrectly, running 3.9 > > Setup: > > create table test1(id1 text PRIMARY KEY, val1 text, val2 text); > > create custom index test1_idx_val1 on test1(val1) using > 'org.apache.cassandra.index.sasi.SASIIndex'; > create custom index test1_idx_val2 on test1(val2) using > 'org.apache.cassandra.index.sasi.SASIIndex'; > > insert into test1(id1, val1, val2) values ('1', '1val1', '1val2'); > insert into test1(id1, val1, val2) values ('2', '~~', '2val2'); > > Queries: > > (1) select * from test1 where val1 = '~~'; > (2) select * from test1 where val1 < '~~' allow filtering; > (3) select * from test1 where val2 = '1val2'; > (4) select * from test1 where val1 < '~~' and val2 = '1val2' allow > filtering; > > 1, 2, and 3 all work correctly. 4 does not work. 2, 3, and 4 should > return the same row (id1='1'); 2 and 3 do, 4 returns 0 rows. > > Weird, because you'd think that if 2 works fine, then 4 ought to as well. > > Anyone else run into this? Not sure if I'm breaking a where-clause rule, > or if I'm running into a bug. > > Thanks. >