cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Benjamin Lerer (JIRA)" <>
Subject [jira] [Commented] (CASSANDRA-6377) ALLOW FILTERING should allow seq scan filtering
Date Mon, 22 Feb 2016 15:46:18 GMT


Benjamin Lerer commented on CASSANDRA-6377:

||Branch||Unit tests||DTests||

[DTest PR|]

In {{2.2}} filtering should have been supported for thrift static column families but the
functionnality was not usable due to some validation checks. The patch for {{2.2}} fix that
problem as well as the validation for the filtering queries without secondary indices. It
also adds some unit tests to verify the correct behavior for filtering queries.

For {{3.x}}, most of the filtering logic has been implemented by CASSANDRA-8099. The patches
add unit tests for filtering, fix the filtering for compact static tables, fix the  filtering
for table with static columns and fix the validation for filtering queries.

Filtering on table with static columns was broken. If a query was filtering out all the rows
of a partition, the static row was not returned to the user (as it was filtered out in SelectStatement)
but it was counted by the paging mechanism. By consequence, if a {{LIMIT}} clause was used
the wrong number of rows were returned.

The Dtest patches removes the error messages validation as it is already tested by the unit
tests and add some tests for filtering with paging.

> ALLOW FILTERING should allow seq scan filtering
> -----------------------------------------------
>                 Key: CASSANDRA-6377
>                 URL:
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: CQL
>            Reporter: Jonathan Ellis
>            Assignee: Benjamin Lerer
>              Labels: cql
>             Fix For: 3.x
> CREATE TABLE emp_table2 (
>         empID int PRIMARY KEY,
>         firstname text,
>         lastname text,
>         b_mon text,
>         b_day text,
>         b_yr text,
> );
> INSERT INTO emp_table2 (empID,firstname,lastname,b_mon,b_day,b_yr) 
>    VALUES (100,'jane','doe','oct','31','1980');
> INSERT INTO emp_table2 (empID,firstname,lastname,b_mon,b_day,b_yr) 
>    VALUES (101,'john','smith','jan','01','1981');
> INSERT INTO emp_table2 (empID,firstname,lastname,b_mon,b_day,b_yr) 
>    VALUES (102,'mary','jones','apr','15','1982');
> INSERT INTO emp_table2 (empID,firstname,lastname,b_mon,b_day,b_yr) 
>    VALUES (103,'tim','best','oct','25','1982');
> SELECT b_mon,b_day,b_yr,firstname,lastname FROM emp_table2 
>     WHERE b_mon='oct' ALLOW FILTERING;
> Bad Request: No indexed columns present in by-columns clause with Equal operator

This message was sent by Atlassian JIRA

View raw message