lirui-apache commented on a change in pull request #10296: 
[FLINK-14691][table]Add use/create/drop/alter database operation and support it 
in flink/blink planner
URL: https://github.com/apache/flink/pull/10296#discussion_r350149826
 
 

 ##########
 File path: 
flink-table/flink-table-common/src/main/java/org/apache/flink/table/catalog/Catalog.java
 ##########
 @@ -145,6 +145,23 @@ void createDatabase(String name, CatalogDatabase 
database, boolean ignoreIfExist
         * @throws CatalogException in case of any runtime exception
         */
        void dropDatabase(String name, boolean ignoreIfNotExists) throws 
DatabaseNotExistException,
+                       DatabaseNotEmptyException, CatalogException;
+
+       /**
+        * Drop a database.
+        *
+        * @param name              Name of the database to be dropped.
+        * @param ignoreIfNotExists Flag to specify behavior when the database 
does not exist:
+        *                          if set to false, throw an exception,
+        *                          if set to true, do nothing.
+        * @param isRestrict        Flag to specify behavior when the database 
contains table:
+        *                          if set to false, delete all tables in the 
database and then delete the database,
+        *                          if set to true, throw an exception.
+        * @throws DatabaseNotExistException if the given database does not 
exist
+        * @throws DatabaseNotEmptyException if the given database is not empty
 
 Review comment:
   ```suggestion
         * @throws DatabaseNotEmptyException if the given database is not empty 
and isRestrict is true
   ```

----------------------------------------------------------------
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]


With regards,
Apache Git Services

Reply via email to