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

Improve error messages emitted during semantic analysis

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.8.0
    • None
    • None
    • Reviewed

    Description

      Follow-up to HIVE-1731.
      A number of issues raised in HIVE-1731 were caused by SemanticAnalyzer not reporting errors correctly.
      Specifically, the following issues need to be addressed:

      • Line numbers are not always provided and sometimes emitted as (0:-1), which is useless
      • Insufficient or unclear context strings are provided

      Specific issues described in HIVE-1731:
      FAILED: Error in semantic analysis: Schema of both sides of union should match: destinationid:_col1 _col2

      • No line/col numbers, context strings provide internal aliases instead of actual column names

      FAILED: Error in semantic analysis: line 0:-1 Both Left and Right Aliases Encountered in Join time

      • Incorrect line/col number info, no context strings to describe the aliases encountered

      FAILED: Error in semantic analysis: AS clause has an invalid number of aliases

      • No line/col numbers, not context string to show the aliases encountered

      FAILED: Error in semantic analysis: line 1:94 Expression Not In Group By Key a

      • testcase: SELECT a.id, VAR(a.cnt) FROM mytable a
      • Context string is unhelpful, needs to provide the actual expression, not just the table reference

      Attachments

        1. HIVE-2155.1.patch
          64 kB
          Syed S. Albiz
        2. HIVE-2155.2.patch
          64 kB
          Syed S. Albiz
        3. HIVE-2155.3.patch
          65 kB
          Syed S. Albiz
        4. HIVE-2155.4.patch
          76 kB
          Syed S. Albiz
        5. HIVE-2155.5.patch
          81 kB
          Syed S. Albiz

        Issue Links

          Activity

            People

              salbiz Syed S. Albiz
              salbiz Syed S. Albiz
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: