cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yogesh Nachnani (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (CASSANDRA-13411) CQL query using the MAX function returns resultset with Row(null, null ...) if data is not found
Date Tue, 25 Apr 2017 16:19:04 GMT

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

Yogesh Nachnani edited comment on CASSANDRA-13411 at 4/25/17 4:18 PM:
----------------------------------------------------------------------

There is actually a test covering this exact use case - testFunctions() in AggregationTest
and explicit comments at multiple places - Selection.java  & GroupMaker.java that say
atleast one row must be returned.
Explicit comments tend to point to it being a feature rather than a bug :) 
[~blerer] to add clarity



was (Author: yogeshnachnani):
There is actually a test covering this exact use case - testFunctions() in AggregationTest
and an explicit comments at multiple places - Selection.java  & GroupMaker.java that say
atleast one row must be returned.
Explicit comments tend to point to it being a feature rather than a bug :) 
[~blerer] to add clarity


> CQL query using the MAX function returns resultset with Row(null, null ...) if data is
not found
> ------------------------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-13411
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-13411
>             Project: Cassandra
>          Issue Type: Bug
>          Components: CQL
>         Environment: 3.10
>            Reporter: Andrew Efimov
>            Priority: Minor
>
> CQL query using the MAX function returns resultset with rows.size=1 if data is not found.
And Row has only null values.
> {{SELECT id, value, MAX(date) FROM table WHERE id = "13411"}}
> If table does not have row by {{id = "13411"}} then session returns ResultSet with Rows.size
= 1 and Row(null, null, null).
> This is a problem to determine whether or not a data has actually been exist.
> I did not check other aggregation functions.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message