godfreyhe commented on a change in pull request #12171:
URL: https://github.com/apache/flink/pull/12171#discussion_r426125201
##########
File path:
flink-table/flink-sql-client/src/main/java/org/apache/flink/table/client/gateway/Executor.java
##########
@@ -133,6 +133,21 @@
*/
List<String> listUserDefinedFunctions(String sessionId) throws
SqlExecutionException;
+ /**
+ * Creates a function with a DDL statement.
+ */
+ void createFunction(String sessionId, String ddl) throws
SqlExecutionException;
Review comment:
I still think we should introduce `executeSql` method instead of three
methods, and i will remove other methods in
https://github.com/apache/flink/pull/12188
##########
File path:
flink-table/flink-sql-client/src/test/java/org/apache/flink/table/client/cli/SqlCommandParserTest.java
##########
@@ -134,6 +134,34 @@ public void testCommands() {
testValidSqlCommand("DROP TABLE IF EXISTS t1", new
SqlCommandCall(SqlCommand.DROP_TABLE, new String[]{"DROP TABLE IF EXISTS t1"}));
testValidSqlCommand("DROP TABLE IF EXISTS catalog1.db1.t1", new
SqlCommandCall(SqlCommand.DROP_TABLE, new String[]{"DROP TABLE IF EXISTS
catalog1.db1.t1"}));
testValidSqlCommand("DROP TABLE IF EXISTS db1.t1", new
SqlCommandCall(SqlCommand.DROP_TABLE, new String[]{"DROP TABLE IF EXISTS
db1.t1"}));
+ // Test create function.
Review comment:
add some tests for `CREATE TEMPORARY SYSTEM FUNCTION`
----------------------------------------------------------------
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]