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

Jacob Isaac commented on PHOENIX-5935:
--------------------------------------

[~gjacoby]  PHOENIX-4179 ensures that the emptyColumn timestamp (since it 
always updated) is used to set the timestamp of the returned Tuple.

Also "testRowTimestampDefault" in PhoenixRowTimestampFunctionIT verifies that 
the emptyColumn timestamp is returned in the case of partial updates.

> Select with non primary keys and PHOENIX_ROW_TIMESTAMP() in where clause fails
> ------------------------------------------------------------------------------
>
>                 Key: PHOENIX-5935
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-5935
>             Project: Phoenix
>          Issue Type: Bug
>            Reporter: Jacob Isaac
>            Assignee: Jacob Isaac
>            Priority: Major
>         Attachments: PHOENIX-5935.4.x.001.patch
>
>
> This fails when COLUMN_ENCODED_BYTES != NON_ENCODED_QUALIFIERS
> Steps to reproduce:-
> CREATE TABLE IF NOT EXISTS N000001 (PK1 INTEGER NOT NULL, PK2 DATE NOT NULL, 
> KV1 VARCHAR, KV2 VARCHAR CONSTRAINT PK PRIMARY KEY(PK1, PK2)) 
> COLUMN_ENCODED_BYTES = 1,IMMUTABLE_STORAGE_SCHEME = ONE_CELL_PER_COLUMN
>  
> SELECT COUNT(*) FROM N000001 WHERE PHOENIX_ROW_TIMESTAMP() > PK2 AND KV1 = 
> 'KV1_1'";
>  
> Fails with the following exception -
> Caused by: java.util.NoSuchElementExceptionCaused by: 
> java.util.NoSuchElementException at 
> org.apache.phoenix.filter.MultiEncodedCQKeyValueComparisonFilter$FilteredKeyValueHolder.getCellAtIndex(MultiEncodedCQKeyValueComparisonFilter.java:151)
>  at 
> org.apache.phoenix.filter.MultiEncodedCQKeyValueComparisonFilter$EncodedCQIncrementalResultTuple.getValue(MultiEncodedCQKeyValueComparisonFilter.java:311)
>  at 
> org.apache.phoenix.expression.function.PhoenixRowTimestampFunction.evaluate(PhoenixRowTimestampFunction.java:98)
>  at 
> org.apache.phoenix.expression.ComparisonExpression.evaluate(ComparisonExpression.java:330)
>  at 
> org.apache.phoenix.expression.AndOrExpression.evaluate(AndOrExpression.java:75)
>  at 
> org.apache.phoenix.filter.BooleanExpressionFilter.evaluate(BooleanExpressionFilter.java:93)
>  at 
> org.apache.phoenix.filter.MultiEncodedCQKeyValueComparisonFilter.filterKeyValue(MultiEncodedCQKeyValueComparisonFilter.java:233)
>  at 
> org.apache.hadoop.hbase.regionserver.querymatcher.UserScanQueryMatcher.matchColumn(UserScanQueryMatcher.java:122)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to