You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hive.apache.org by "Szehon Ho (JIRA)" <ji...@apache.org> on 2015/04/08 21:24:13 UTC

[jira] [Updated] (HIVE-10265) Hive CLI crashes on != inequality

     [ https://issues.apache.org/jira/browse/HIVE-10265?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Szehon Ho updated HIVE-10265:
-----------------------------
    Attachment: HIVE-10265.patch

Looked at Beeline, the difference is that Jline ConsoleReader is initialized with 'expandEvents'.  It fixes the issue for me, giving it a try to see if it breaks anything else in CliDriver tests.

This is also mentioned in a Jline issue: [https://github.com/jline/jline2/issues/96|https://github.com/jline/jline2/issues/96]

> Hive CLI crashes on != inequality
> ---------------------------------
>
>                 Key: HIVE-10265
>                 URL: https://issues.apache.org/jira/browse/HIVE-10265
>             Project: Hive
>          Issue Type: Bug
>          Components: CLI
>    Affects Versions: 1.1.0
>            Reporter: Szehon Ho
>         Attachments: HIVE-10265.patch
>
>
> It seems != is a supported inequality operator according to: [https://cwiki.apache.org/confluence/display/Hive/LanguageManual+UDF#LanguageManualUDF-Built-inOperators|https://cwiki.apache.org/confluence/display/Hive/LanguageManual+UDF#LanguageManualUDF-Built-inOperators].
> However, HiveCLI crashes if we try a query:
> {noformat}
> hive> select * from src where key != '10';
> [ERROR] Could not expand event
> java.lang.IllegalArgumentException: != '10';: event not found
> 	at jline.console.ConsoleReader.expandEvents(ConsoleReader.java:779)
> 	at jline.console.ConsoleReader.finishBuffer(ConsoleReader.java:631)
> 	at jline.console.ConsoleReader.accept(ConsoleReader.java:2019)
> 	at jline.console.ConsoleReader.readLine(ConsoleReader.java:2666)
> 	at jline.console.ConsoleReader.readLine(ConsoleReader.java:2269)
> 	at org.apache.hadoop.hive.cli.CliDriver.executeDriver(CliDriver.java:730)
> 	at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:681)
> 	at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:621)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> 	at java.lang.reflect.Method.invoke(Method.java:606)
> 	at org.apache.hadoop.util.RunJar.run(RunJar.java:221)
> 	at org.apache.hadoop.util.RunJar.main(RunJar.java:136)
> {noformat}
> Beeline is also based on jline and does not crash.
> Current Hive is on jline-2.12.



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