T Jake Luciani created CASSANDRA-8270: -----------------------------------------
Summary: Allow sub slices for composites Key: CASSANDRA-8270 URL: https://issues.apache.org/jira/browse/CASSANDRA-8270 Project: Cassandra Issue Type: Improvement Reporter: T Jake Luciani Priority: Minor For some queries with clustering keys it would be helpful to allow server side to avoid processing things you will simply filter out. Example schema: {code} create TABLE foo (a text, b int, c int, d int, primary key(a, b, c)); insert into foo (a, b, c, d ) VALUES ( 'key', 2, 3, 4); insert into foo (a, b, c, d ) VALUES ( 'key', 2, 4, 4); insert into foo (a, b, c, d ) VALUES ( 'key', 3, 3, 4); insert into foo (a, b, c, d ) VALUES ( 'key', 3, 4, 4); {code} {code} select count(*) from foo where a = 'key' and b = 2 and c > 3; --return 1 select count(*) from foo where a = 'key' and b > 2 and c > 3; --error select count(*) from foo where a = 'key' and c > 3; --error {code} The first query is only possible because our slices only allow a fixed prefix but if we extended slices to include slices we could effectively request for: b(2,*) c (3,*) b (*,*) c (3,*) -- This message was sent by Atlassian JIRA (v6.3.4#6332)