[ 
https://issues.apache.org/jira/browse/HIVE-21884?focusedWorklogId=324747&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-324747
 ]

ASF GitHub Bot logged work on HIVE-21884:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 07/Oct/19 23:46
            Start Date: 07/Oct/19 23:46
    Worklog Time Spent: 10m 
      Work Description: jcamachor commented on pull request #794: HIVE-21884
URL: https://github.com/apache/hive/pull/794#discussion_r332274057
 
 

 ##########
 File path: ql/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g
 ##########
 @@ -2066,6 +2074,71 @@ dropMaterializedViewStatement
     : KW_DROP KW_MATERIALIZED KW_VIEW ifExists? viewName -> 
^(TOK_DROP_MATERIALIZED_VIEW viewName ifExists?)
     ;
 
+createScheduledQueryStatement
+@init { pushMsg("create scheduled query statement", state); }
+@after { popMsg(state); }
+    : KW_CREATE KW_SCHEDULED KW_QUERY name=identifier
+        scheduleSpec
+        executedAsSpec?
+        enableSpecification?
+        definedAsSpec
+    -> ^(TOK_CREATE_SCHEDULED_QUERY
+            $name
+            scheduleSpec
+            executedAsSpec?
+            enableSpecification?
+            definedAsSpec
+        )
+    ;
+    
+dropScheduledQueryStatement
+@init { pushMsg("drop scheduled query statement", state); }
+@after { popMsg(state); }
+    : KW_DROP KW_SCHEDULED KW_QUERY name=identifier
+    -> ^(TOK_DROP_SCHEDULED_QUERY
+            $name
+        )
+    ;
+
+    
+alterScheduledQueryStatement
+@init { pushMsg("alter scheduled query statement", state); }
+@after { popMsg(state); }
+    : KW_ALTER KW_SCHEDULED KW_QUERY name=identifier
+            mod=alterScheduledQueryChange
+    -> ^(TOK_ALTER_SCHEDULED_QUERY
+            $name
+            $mod
+        )
+    ;
+    
+alterScheduledQueryChange
+@init { pushMsg("alter scheduled query change", state); }
+@after { popMsg(state); }
+    : scheduleSpec
+    | executedAsSpec
+    | enableSpecification
+    | definedAsSpec
+    ;
+
+scheduleSpec
+@init { pushMsg("schedule specification", state); }
+@after { popMsg(state); }
+        : KW_CRON cronString=StringLiteral -> ^(TOK_CRON $cronString)
+        ;
+
+executedAsSpec
+@init { pushMsg("executedAs specification", state); }
+@after { popMsg(state); }
+        : KW_EXECUTED KW_AS executedAs=StringLiteral -> ^(TOK_EXECUTED_AS 
$executedAs)
+        ;
+
+definedAsSpec
+@init { pushMsg("definedAs specification", state); }
+@after { popMsg(state); }
+        : KW_DEFINED? KW_AS statement -> ^(TOK_QUERY statement)
 
 Review comment:
   I think we can remove `DEFINED`, since it is redundant and we do not use it 
for most statements.
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 324747)
    Time Spent: 2h 50m  (was: 2h 40m)

> Scheduled query support
> -----------------------
>
>                 Key: HIVE-21884
>                 URL: https://issues.apache.org/jira/browse/HIVE-21884
>             Project: Hive
>          Issue Type: Improvement
>            Reporter: Zoltan Haindrich
>            Assignee: Zoltan Haindrich
>            Priority: Major
>              Labels: pull-request-available
>         Attachments: HIVE-21844.04.patch, HIVE-21844.05.patch, 
> HIVE-21844.06.patch, HIVE-21844.07.patch, HIVE-21844.08.patch, 
> HIVE-21844.09.patch, HIVE-21844.15.patch, HIVE-21844.19.patch, 
> HIVE-21884.01.patch, HIVE-21884.02.patch, HIVE-21884.03.patch, 
> HIVE-21884.09.patch, HIVE-21884.10.patch, HIVE-21884.10.patch, 
> HIVE-21884.11.patch, HIVE-21884.12.patch, HIVE-21884.13.patch, 
> HIVE-21884.14.patch, HIVE-21884.14.patch, HIVE-21884.14.patch, 
> HIVE-21884.16.patch, HIVE-21884.17.patch, HIVE-21884.18.patch, 
> HIVE-21884.20.patch, Scheduled queries2.pdf
>
>          Time Spent: 2h 50m
>  Remaining Estimate: 0h
>
> design document:
> https://docs.google.com/document/d/1mJSFdJi_1cbxJTXC9QvGw2rQ3zzJkNfxOO6b5esmyCE/edit#
> in case the google doc is not reachable:  [^Scheduled queries2.pdf] 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to