You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@phoenix.apache.org by "Thomas D'Silva (JIRA)" <ji...@apache.org> on 2019/01/16 00:54:00 UTC
[jira] [Created] (PHOENIX-5102) Filtering on DATE types throws an
exception using the spark connector
Thomas D'Silva created PHOENIX-5102:
---------------------------------------
Summary: Filtering on DATE types throws an exception using the spark connector
Key: PHOENIX-5102
URL: https://issues.apache.org/jira/browse/PHOENIX-5102
Project: Phoenix
Issue Type: Bug
Reporter: Thomas D'Silva
Assignee: Thomas D'Silva
Fix For: connectors-1.0.0
SELECT * FROM DATE_TEST WHERE COL1 > TO_DATE('1990-01-01 00:00:01', 'yyyy-MM-dd HH:mm:ss')
Filtering on a DATE column fails with the following exception:
{code}
Caused by: org.apache.phoenix.schema.TypeMismatchException: ERROR 203 (22005): Type mismatch. DATE and BIGINT for "COL1" > 1988
at org.apache.phoenix.schema.TypeMismatchException.newException(TypeMismatchException.java:53)
at org.apache.phoenix.expression.ComparisonExpression.create(ComparisonExpression.java:149)
at org.apache.phoenix.compile.ExpressionCompiler.visitLeave(ExpressionCompiler.java:234)
at org.apache.phoenix.compile.ExpressionCompiler.visitLeave(ExpressionCompiler.java:146)
at org.apache.phoenix.parse.ComparisonParseNode.accept(ComparisonParseNode.java:47)
at org.apache.phoenix.parse.CompoundParseNode.acceptChildren(CompoundParseNode.java:64)
at org.apache.phoenix.parse.AndParseNode.accept(AndParseNode.java:47)
at org.apache.phoenix.compile.WhereCompiler.compile(WhereCompiler.java:138)
at org.apache.phoenix.compile.WhereCompiler.compile(WhereCompiler.java:108)
at org.apache.phoenix.compile.QueryCompiler.compileSingleFlatQuery(QueryCompiler.java:559)
at org.apache.phoenix.compile.QueryCompiler.compileSingleQuery(QueryCompiler.java:510)
at org.apache.phoenix.compile.QueryCompiler.compileSelect(QueryCompiler.java:195)
at org.apache.phoenix.compile.QueryCompiler.compile(QueryCompiler.java:155)
at org.apache.phoenix.jdbc.PhoenixStatement$ExecutableSelectStatement.compilePlan(PhoenixStatement.java:490)
at org.apache.phoenix.jdbc.PhoenixStatement$ExecutableSelectStatement.compilePlan(PhoenixStatement.java:456)
at org.apache.phoenix.jdbc.PhoenixStatement.compileQuery(PhoenixStatement.java:1745)
at org.apache.phoenix.jdbc.PhoenixStatement.compileQuery(PhoenixStatement.java:1738)
at org.apache.phoenix.jdbc.PhoenixStatement.optimizeQuery(PhoenixStatement.java:1732)
at org.apache.phoenix.spark.datasource.v2.reader.PhoenixDataSourceReader.planInputPartitions(PhoenixDataSourceReader.java:137)
... 94 more
{code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)