You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@impala.apache.org by "Tim Armstrong (JIRA)" <ji...@apache.org> on 2017/11/20 21:50:00 UTC

[jira] [Created] (IMPALA-6224) impala-shell exits with error "No closing quotation" with certain syntactic errors

Tim Armstrong created IMPALA-6224:
-------------------------------------

             Summary: impala-shell exits with error "No closing quotation" with certain syntactic errors
                 Key: IMPALA-6224
                 URL: https://issues.apache.org/jira/browse/IMPALA-6224
             Project: IMPALA
          Issue Type: Bug
          Components: Clients
            Reporter: Tim Armstrong


{code}
with v as (select 1)
select foo('\\'), ('bar
;
{code}

Pasting the above into impala-shell results in the shell exiting with an error. It should print a syntax error but the shell should not exit:
{noformat}
[localhost:21000] > with v as (select 1)
                  > select foo('\\'), ('bar
                  > ;
Traceback (most recent call last):
  File "/home/tarmstrong/Impala/incubator-impala/shell/impala_shell.py", line 1541, in <module>
    shell.cmdloop(intro)
  File "/usr/lib/python2.7/cmd.py", line 142, in cmdloop
    stop = self.onecmd(line)
  File "/home/tarmstrong/Impala/incubator-impala/shell/impala_shell.py", line 558, in onecmd
    return cmd.Cmd.onecmd(self, line)
  File "/usr/lib/python2.7/cmd.py", line 221, in onecmd
    return func(arg)
  File "/home/tarmstrong/Impala/incubator-impala/shell/impala_shell.py", line 1087, in do_with
    tokens = list(lexer)
  File "/usr/lib/python2.7/shlex.py", line 269, in next
    token = self.get_token()
  File "/usr/lib/python2.7/shlex.py", line 96, in get_token
    raw = self.read_token()
  File "/usr/lib/python2.7/shlex.py", line 172, in read_token
    raise ValueError, "No closing quotation"
ValueError: No closing quotation
{noformat}

The repro query is a reduced version of a more complex query reported by a customer.




--
This message was sent by Atlassian JIRA
(v6.4.14#64029)