Hive
  1. Hive
  2. HIVE-5614

Subquery support: allow subquery expressions in having clause

    Details

    • Type: New Feature New Feature
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.13.0
    • Component/s: Query Processor
    • Labels:
      None
    1. HIVE-5614.4.patch
      136 kB
      Harish Butani
    2. HIVE-5614.3.patch
      99 kB
      Harish Butani
    3. HIVE-5614.2.patch
      99 kB
      Harish Butani
    4. HIVE-5614.1.patch
      85 kB
      Harish Butani

      Issue Links

        Activity

        Harish Butani created issue -
        Harish Butani made changes -
        Field Original Value New Value
        Link This issue is part of HIVE-784 [ HIVE-784 ]
        Harish Butani made changes -
        Assignee Harish Butani [ rhbutani ]
        Harish Butani made changes -
        Link This issue depends upon HIVE-3107 [ HIVE-3107 ]
        Harish Butani made changes -
        Attachment HIVE-5614.1.patch [ 12613418 ]
        Hide
        Harish Butani added a comment -

        uploaded preliminary patch.
        Includes changes for HIVE-3107

        Show
        Harish Butani added a comment - uploaded preliminary patch. Includes changes for HIVE-3107
        Harish Butani made changes -
        Attachment HIVE-5614.2.patch [ 12614113 ]
        Hide
        Harish Butani added a comment -
        Show
        Harish Butani added a comment - review request at https://reviews.apache.org/r/15584/
        Harish Butani made changes -
        Attachment HIVE-5614.3.patch [ 12614936 ]
        Hide
        Harish Butani added a comment -
        Show
        Harish Butani added a comment - review request at https://reviews.apache.org/r/15718/
        Harish Butani made changes -
        Status Open [ 1 ] Patch Available [ 10002 ]
        Hide
        Hive QA added a comment -

        Overall: +1 all checks pass

        Here are the results of testing the latest attachment:
        https://issues.apache.org/jira/secure/attachment/12614936/HIVE-5614.3.patch

        SUCCESS: +1 4684 tests passed

        Test results: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/381/testReport
        Console output: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/381/console

        Messages:

        Executing org.apache.hive.ptest.execution.PrepPhase
        Executing org.apache.hive.ptest.execution.ExecutionPhase
        Executing org.apache.hive.ptest.execution.ReportingPhase
        

        This message is automatically generated.

        ATTACHMENT ID: 12614936

        Show
        Hive QA added a comment - Overall : +1 all checks pass Here are the results of testing the latest attachment: https://issues.apache.org/jira/secure/attachment/12614936/HIVE-5614.3.patch SUCCESS: +1 4684 tests passed Test results: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/381/testReport Console output: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/381/console Messages: Executing org.apache.hive.ptest.execution.PrepPhase Executing org.apache.hive.ptest.execution.ExecutionPhase Executing org.apache.hive.ptest.execution.ReportingPhase This message is automatically generated. ATTACHMENT ID: 12614936
        Hide
        Ashutosh Chauhan added a comment -

        Some comments on RB.

        Show
        Ashutosh Chauhan added a comment - Some comments on RB.
        Ashutosh Chauhan made changes -
        Status Patch Available [ 10002 ] Open [ 1 ]
        Harish Butani made changes -
        Attachment HIVE-5614.4.patch [ 12615417 ]
        Harish Butani made changes -
        Status Open [ 1 ] Patch Available [ 10002 ]
        Hide
        Harish Butani added a comment -

        update based on feedback from Ashutosh Chauhan.

        Show
        Harish Butani added a comment - update based on feedback from Ashutosh Chauhan .
        Hide
        Ashutosh Chauhan added a comment -

        +1

        Show
        Ashutosh Chauhan added a comment - +1
        Hide
        Hive QA added a comment -

        Overall: +1 all checks pass

        Here are the results of testing the latest attachment:
        https://issues.apache.org/jira/secure/attachment/12615417/HIVE-5614.4.patch

        SUCCESS: +1 4684 tests passed

        Test results: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/410/testReport
        Console output: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/410/console

        Messages:

        Executing org.apache.hive.ptest.execution.PrepPhase
        Executing org.apache.hive.ptest.execution.ExecutionPhase
        Executing org.apache.hive.ptest.execution.ReportingPhase
        

        This message is automatically generated.

        ATTACHMENT ID: 12615417

        Show
        Hive QA added a comment - Overall : +1 all checks pass Here are the results of testing the latest attachment: https://issues.apache.org/jira/secure/attachment/12615417/HIVE-5614.4.patch SUCCESS: +1 4684 tests passed Test results: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/410/testReport Console output: http://bigtop01.cloudera.org:8080/job/PreCommit-HIVE-Build/410/console Messages: Executing org.apache.hive.ptest.execution.PrepPhase Executing org.apache.hive.ptest.execution.ExecutionPhase Executing org.apache.hive.ptest.execution.ReportingPhase This message is automatically generated. ATTACHMENT ID: 12615417
        Hide
        Ashutosh Chauhan added a comment -

        Committed to trunk. Thanks, Harish!

        Show
        Ashutosh Chauhan added a comment - Committed to trunk. Thanks, Harish!
        Ashutosh Chauhan made changes -
        Status Patch Available [ 10002 ] Resolved [ 5 ]
        Fix Version/s 0.13.0 [ 12324986 ]
        Resolution Fixed [ 1 ]
        Hide
        Lefty Leverenz added a comment -

        This should be documented in the wiki, either in "HAVING Clause" on the "Select" page or in a new section on the "Subqueries" page, or both:

        Also, the general syntax for SELECT omits HAVING and some other clauses. Is the complete syntax documented anywhere? Does anyone have time to update it (or to review it if I give it a try)?

        Show
        Lefty Leverenz added a comment - This should be documented in the wiki, either in "HAVING Clause" on the "Select" page or in a new section on the "Subqueries" page, or both: HAVING Clause Subqueries Also, the general syntax for SELECT omits HAVING and some other clauses. Is the complete syntax documented anywhere? Does anyone have time to update it (or to review it if I give it a try)? Select Syntax
        Hide
        Harish Butani added a comment -

        [~lefty@hortonworks.com] I suggest we add a new section: 'SubQuery predicates in the where and having clauses'.
        There are a lot of examples and behavior details in the Spec attached on jira HIVE-784.
        Also lots of e.g.s in the tests, look for subquery.*.q files.
        Can you take a shot at this.

        Show
        Harish Butani added a comment - [~lefty@hortonworks.com] I suggest we add a new section: 'SubQuery predicates in the where and having clauses'. There are a lot of examples and behavior details in the Spec attached on jira HIVE-784 . Also lots of e.g.s in the tests, look for subquery.*.q files. Can you take a shot at this.
        Hide
        Lefty Leverenz added a comment -

        Happy to help. I'd forgotten about that spec, thanks for the reminder.

        Show
        Lefty Leverenz added a comment - Happy to help. I'd forgotten about that spec, thanks for the reminder.

          People

          • Assignee:
            Harish Butani
            Reporter:
            Harish Butani
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development