Thanks FG for your recommendations. Let me try that. Thanks for your time. On Thursday, February 17, 2022, 04:40:07 AM EST, Francesco Guardiani <france...@ververica.com> wrote: Hi, The SQL syntax is not supported, as the SQL standard itself does not allow it. It sounds strange that it fails at validation phase rather than when parsing, but it shouldn't work anyway. I suggest you to just use Table API for that, as it's richer. You can even use withColumns(range(..)) which gives you more control. Hope it helps,FG
On Thu, Feb 17, 2022 at 1:34 AM M Singh <mans2si...@yahoo.com> wrote: Hi: I have a simple concatenate UDF (for testing purpose) defined as: public static class ConcatenateFunction extends ScalarFunction { public String eval(@DataTypeHint(inputGroup = InputGroup.ANY) Object ... inputs) { return Arrays.stream(inputs).map(i -> i.toString()).collect( Collectors.joining(",")); } } and register it with the streaming table env: tEnv.createTemporarySystemFunction("concatenateFunction", ConcatenateFunction.class); However when I call the function as shown below - I get an exception indicating that the '*' is an unknown identifier as shown below. Table concat = tEnv.sqlQuery( "SELECT concatenateFunction(*) " + "FROM test_table" ); I am printing the rows at the end of the test application. The exception is: Exception in thread "main" org.apache.flink.table.api.ValidationException: SQL validation failed. At line 1, column 29: Unknown identifier '*' The document (User-defined Functions) shows how to call the function with all args using scala/java : env.from("MyTable").select(call(MyConcatFunction.class, $("*"))); But I could not find how to call the UDF using SQL syntax as shown above (select concatenateFunction(*) from test_table). Can you please let me know if there a way to pass all arguments to a UDF in SQL ? Thanks