cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Benjamin Lerer (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CASSANDRA-12977) column expire to null can still be retrieved using not null value in where clause
Date Thu, 01 Dec 2016 08:58:58 GMT

    [ https://issues.apache.org/jira/browse/CASSANDRA-12977?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15711387#comment-15711387
] 

Benjamin Lerer commented on CASSANDRA-12977:
--------------------------------------------

It effectively looks like a bug. Thanks for reporting the problem.

> column expire to null can still be retrieved using not null value in where clause
> ---------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-12977
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-12977
>             Project: Cassandra
>          Issue Type: Bug
>          Components: CQL
>         Environment: cql  5.0.1
> cassandra 2.1.5
>            Reporter: ruilonghe1988
>            Assignee: Benjamin Lerer
>         Attachments: attatchment.txt, attatchment.txt
>
>
> 1. first create table:
> create table device_share(
> device_id text primary key,
> share_status text,
> share_expire boolean
> );
> CREATE INDEX expireIndex ON device_share (share_expire);
> create index statusIndex ON device_share (share_status);
> 2.insert a new record:
> insert into device_share(device_id,share_status,share_expire) values ('d1','ready',false);
> 3. update the share_expire value to fase with ttl 20
> update device_share using ttl 20 set share_expire = false where device_id = 'd1';
> 4.after 20 seconds, can retrieve the record with condition where share_expire = false,
but the record in the console show the share_expire is null.
> cqlsh:test> select * from device_share where device_id ='d1' and share_status='ready'
and share_expire = false allow filtering;
>  device_id | share_expire | share_status
> -----------+--------------+--------------
>         d1 |         null |        ready
> is this a bug?



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message