Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-12362 Create a full-fledged built-in SQL parser
  3. SPARK-12577

better support of parentheses in partition by and order by clause of window function's over clause

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 2.0.0
    • SQL
    • None

    Description

      Right now, Hive's parser support

      -- PASS
      SELECT SUM(1) OVER (PARTITION BY a + 1 - b * c / d FROM src;
      SELECT SUM(1) OVER (PARTITION BY (a + 1 - b * c / d) FROM src;
      

      But, the following one is not accepted

      -- FAIL
      SELECT SUM(1) OVER (PARTITION BY (a) + 1 - b * c / d) FROM src;
      

      We should fix it in our own parser.

      Attachments

        Activity

          People

            viirya L. C. Hsieh
            rxin Reynold Xin
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: