nrg4878 commented on a change in pull request #2037:
URL: https://github.com/apache/hive/pull/2037#discussion_r597392174



##########
File path: parser/src/java/org/apache/hadoop/hive/ql/parse/CreateDDLParser.g
##########
@@ -108,3 +108,45 @@ createTableStatement
          selectStatementWithCTE?
         )
     ;
+
+createDataConnectorStatement
+@init { gParent.pushMsg("create connector statement", state); }
+@after { gParent.popMsg(state); }
+    : KW_CREATE KW_DATACONNECTOR ifNotExists? name=identifier 
dataConnectorType dataConnectorUrl dataConnectorComment? ( KW_WITH 
KW_DCPROPERTIES dcprops=dcProperties)?
+    -> ^(TOK_CREATEDATACONNECTOR $name ifNotExists? dataConnectorType 
dataConnectorUrl dataConnectorComment? $dcprops?)
+    ;
+
+dataConnectorComment
+@init { gParent.pushMsg("dataconnector comment", state); }
+@after { gParent.popMsg(state); }
+    : KW_COMMENT comment=StringLiteral
+    -> ^(TOK_DATACONNECTORCOMMENT $comment)
+    ;
+
+dataConnectorUrl
+@init { gParent.pushMsg("dataconnector URL", state); }
+@after { gParent.popMsg(state); }
+    : KW_URL url=StringLiteral
+    -> ^(TOK_DATACONNECTORURL $url)
+    ;
+
+dataConnectorType
+@init { gParent.pushMsg("dataconnector type", state); }
+@after { gParent.popMsg(state); }
+    : KW_TYPE dcType=StringLiteral
+    -> ^(TOK_DATACONNECTORTYPE $dcType)
+    ;
+
+dcProperties
+@init { gParent.pushMsg("dcproperties", state); }
+@after { gParent.popMsg(state); }
+    :
+      LPAREN dbPropertiesList RPAREN -> ^(TOK_DATACONNECTORPROPERTIES 
dbPropertiesList)
+    ;
+
+dropDataConnectorStatement
+@init { gParent.pushMsg("drop connector statement", state); }
+@after { gParent.popMsg(state); }
+    : KW_DROP (KW_DATACONNECTOR) ifExists? identifier

Review comment:
       () shouldn't be needed. I will make a note of this and remove this in a 
sub-sequent patch as I will have to re-run tests.




-- 
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:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to