You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2021/04/08 06:29:20 UTC

[GitHub] [shardingsphere] tristaZero commented on a change in pull request #9940: Support oracle alter partition grammar

tristaZero commented on a change in pull request #9940:
URL: https://github.com/apache/shardingsphere/pull/9940#discussion_r609348445



##########
File path: shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-oracle/src/main/antlr4/imports/oracle/DDLStatement.g4
##########
@@ -919,3 +919,31 @@ flashbackArchiveClause
 alterSynonym
     : ALTER PUBLIC? SYNONYM (schemaName DOT_)? synonymName (COMPILE | EDITIONABLE | NONEDITIONABLE)
     ;
+
+alterTablePartition
+    : addTablePartition | dropTablePartition
+    ;
+
+addTablePartition
+    : ADD (addRangePartitionClause | addListPartitionClause)
+    ;
+
+addRangePartitionClause
+    : PARTITION partitionName? rangeValuesClause tablePartitionDescription
+    ((LP_? rangeSubpartitionDesc (COMMA_ rangeSubpartitionDesc)* | listSubpartitionDesc (COMMA_ listSubpartitionDesc)* | individualHashSubparts (COMMA_ individualHashSubparts)* RP_?)
+        | hashSubpartitionQuantity)?
+    ;
+
+addListPartitionClause
+    : PARTITION partitionName? listValuesClause tablePartitionDescription
+    ((LP_? rangeSubpartitionDesc (COMMA_ rangeSubpartitionDesc)* | listSubpartitionDesc (COMMA_ listSubpartitionDesc)* | individualHashSubparts (COMMA_ individualHashSubparts)* RP_?)
+    | hashSubpartitionQuantity)?
+    ;
+

Review comment:
       Hi, We can have a plan to support this grammar completely. Firstly, we can add the whole grammar definition, then we can consider improve the class of `CreateTableStatement`.




-- 
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:
users@infra.apache.org