dawidwys commented on a change in pull request #11280: [FLINK-16377][table] Support inline user defined functions in expression dsl URL: https://github.com/apache/flink/pull/11280#discussion_r397903751
########## File path: flink-table/flink-table-planner/src/test/java/org/apache/flink/table/runtime/stream/sql/FunctionITCase.java ########## @@ -444,6 +450,31 @@ private void testUserDefinedCatalogFunction(TableEnvironment tableEnv, String cr tableEnv.sqlUpdate("drop table t2"); } + @Test + public void testDataTypeBasedTypeInferenceNotSupported() throws Exception { + thrown.expect(ValidationException.class); + thrown.expectMessage("The new type inference for functions is only supported in the Blink planner."); + + StreamExecutionEnvironment streamExecEnvironment = StreamExecutionEnvironment.getExecutionEnvironment(); + StreamTableEnvironment tableEnvironment = StreamTableEnvironment.create(streamExecEnvironment); + + tableEnvironment.createTemporarySystemFunction("func", SimpleScalarFunction.class); + Table table = tableEnvironment + .sqlQuery("SELECT func(1)"); + tableEnvironment.toAppendStream(table, Row.class).print(); + + streamExecEnvironment.execute(); + } + + /** Review comment: Will simplify it. ---------------------------------------------------------------- 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 With regards, Apache Git Services