Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-8396

Hive CliDriver command splitting can be broken when comments are present

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 0.14.0
    • 1.3.0, 2.0.0
    • Parser, Query Processor
    • None
    • Hive interactive shell now strips full line comments from the input, matching the behaviour of hive -f, beeline (interactive), and beeline -f.

    Description

      -- SORT_QUERY_RESULTS
      set hive.cbo.enable=true;
      
      ... commands ...
      

      causes

      2014-10-07 18:55:57,193 ERROR ql.Driver (SessionState.java:printError(825)) - FAILED: ParseException line 2:4 missing KW_ROLE at 'hive' near 'hive'
      

      If the comment is moved after the command it works.

      I noticed this earlier when I comment out parts of some random q file for debugging purposes, and it starts failing. This is annoying.

      Attachments

        1. HIVE-8396.01.patch
          0.6 kB
          Sergey Shelukhin
        2. HIVE-8396.0.patch
          0.6 kB
          Elliot West

        Activity

          People

            teabot Elliot West
            sershe Sergey Shelukhin
            Votes:
            3 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: