Uploaded image for project: 'IMPALA'
  1. IMPALA
  2. IMPALA-4184

impala-shell should auto-detect when being used non-interactively

Attach filesAttach ScreenshotAdd voteVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Workaround: Use -q or -f flags to force impala-shell into non-interactive mode.

    Description

      $ impala-shell < impalatest.sql;echo $?
      Starting Impala Shell without Kerberos authentication
      Connected to host-10-17-101:21000
      Server version: impalad version 2.5.0-cdh5.7.0 RELEASE (build ad3f5adabedf56fe6bd9eea39147c067cc552703)

      Query: sdkfsdkfj
      ERROR: AnalysisException: Syntax error in line 1:
      sdkfsdkfj
      ^
      Encountered: IDENTIFIER
      Expected: ALTER, COMPUTE, CREATE, DESCRIBE, DROP, EXPLAIN, GRANT, INSERT, INVALIDATE, LOAD, REFRESH, REVOKE, SELECT, SET, SHOW, TRUNCATE, USE, VALUES, WITH

      CAUSED BY: Exception: Syntax error

      Goodbye root

      $ 0

      Notice 0 return code even though query 'sdkfsdkfj' had a syntax error.

      This impala-shell behavior is inconsistent with other CLI tools return code
      like beeline, hive, spark-shell etc.

      We have to process return code so the whole workflow has to stop and send notification
      if impala-shell has failed.

      This issue only occurs if the -f query option is not specified.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            Unassigned Unassigned
            tagar_impala_e3b3 Ruslan Dautkhanov

            Dates

              Created:
              Updated:

              Slack

                Issue deployment