hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gopal V (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HIVE-12404) Orc ppd throws exception if types don't match
Date Sat, 14 Nov 2015 06:05:11 GMT

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

Gopal V commented on HIVE-12404:
--------------------------------

The semantics needs a fix, this is handled for some of the numeric types in TypeCheckProcFactory.

{code}
        // Try to infer the type of the constant only if there are two
        // nodes, one of them is column and the other is numeric const
{code}

That's the case which needs to inject an inference for Boolean.

bq. such questionable semantics ORC should be defensive and should turn off ppd

The value class equality is complex when you do something like {{cbyte > 0}} or {{cbigint
> 0}}.

This approach might be defensive, but to handle it optimally this patch needs to handle all
the implicit inferences implemented for HIVE-10286.

> Orc ppd throws exception if types don't match
> ---------------------------------------------
>
>                 Key: HIVE-12404
>                 URL: https://issues.apache.org/jira/browse/HIVE-12404
>             Project: Hive
>          Issue Type: Bug
>          Components: ORC
>    Affects Versions: 2.0.0
>            Reporter: Ashutosh Chauhan
>            Assignee: Ashutosh Chauhan
>         Attachments: HIVE-12404.patch
>
>
> When type of constant value and column doesn't match, currently Hive throws up.
> {code}
> java.lang.IllegalArgumentException: Wrong value class java.lang.Integer for BOOLEAN.LESS_THAN_EQUALS
leaf
>         at org.apache.hadoop.hive.ql.io.sarg.SearchArgumentImpl$PredicateLeafImpl.<init>(SearchArgumentImpl.java:63)
>         at org.apache.hadoop.hive.ql.io.sarg.SearchArgumentImpl$BuilderImpl.lessThanEquals(SearchArgumentImpl.java:304)
>         at org.apache.hadoop.hive.ql.io.sarg.ConvertAstToSearchArg.createLeaf(ConvertAstToSearchArg.java:277)
>         at org.apache.hadoop.hive.ql.io.sarg.ConvertAstToSearchArg.createLeaf(ConvertAstToSearchArg.java:326)
>         at org.apache.hadoop.hive.ql.io.sarg.ConvertAstToSearchArg.parse(ConvertAstToSearchArg.java:386)
>         at org.apache.hadoop.hive.ql.io.sarg.ConvertAstToSearchArg.addChildren(ConvertAstToSearchArg.java:331)
>         at org.apache.hadoop.hive.ql.io.sarg.ConvertAstToSearchArg.parse(ConvertAstToSearchArg.java:370)
>         at org.apache.hadoop.hive.ql.io.sarg.ConvertAstToSearchArg.addChildren(ConvertAstToSearchArg.java:331)
>         at org.apache.hadoop.hive.ql.io.sarg.ConvertAstToSearchArg.parse(ConvertAstToSearchArg.java:366)
>         at org.apache.hadoop.hive.ql.io.sarg.ConvertAstToSearchArg.<init>(ConvertAstToSearchArg.java:68)
>         at org.apache.hadoop.hive.ql.io.sarg.ConvertAstToSearchArg.create(ConvertAstToSearchArg.java:417)
>         at org.apache.hadoop.hive.ql.io.sarg.ConvertAstToSearchArg.createFromConf(ConvertAstToSearchArg.java:436)
>         at org.apache.hadoop.hive.ql.io.orc.OrcInputFormat$Context.<init>(OrcInputFormat.java:484)
>         at org.apache.hadoop.hive.ql.io.orc.OrcInputFormat.generateSplitsInfo(OrcInputFormat.java:1121)
>         at org.apache.hadoop.hive.ql.io.orc.OrcInputFormat.getSplits(OrcInputFormat.java:1207)
>         at org.apache.hadoop.hive.ql.io.HiveInputFormat.addSplitsForGroup(HiveInputFormat.java:369)
>         at org.apache.hadoop.hive.ql.io.HiveInputFormat.getSplits(HiveInputFormat.java:481)
>         at org.apache.hadoop.hive.ql.exec.tez.HiveSplitGenerator.initialize(HiveSplitGenerator.java:160)
> {code}



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

Mime
View raw message