[ 
https://issues.apache.org/jira/browse/FLINK-7678?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16249554#comment-16249554
 ] 

ASF GitHub Bot commented on FLINK-7678:
---------------------------------------

Github user twalthr commented on a diff in the pull request:

    https://github.com/apache/flink/pull/4726#discussion_r150539194
  
    --- Diff: 
flink-libraries/flink-table/src/test/scala/org/apache/flink/table/expressions/UserDefinedScalarFunctionTest.scala
 ---
    @@ -89,6 +90,14 @@ class UserDefinedScalarFunctionTest extends 
ExpressionTestBase {
           "Nullable(f0)",
           "Nullable(f0)",
           "42")
    +
    +    // test row type input
    +    testAllApis(
    +      Func19('f11),
    +      "Func19(f11)",
    +      "Func19(f11)",
    +      "12,true,1,2,3"
    --- End diff --
    
    No flattening is happening here. It calls the `toString` method of `Row`. 
If it would be flattened, then only the first field would be returned by the 
test base.


> SQL UserDefineTableFunction does not take CompositeType input correctly
> -----------------------------------------------------------------------
>
>                 Key: FLINK-7678
>                 URL: https://issues.apache.org/jira/browse/FLINK-7678
>             Project: Flink
>          Issue Type: Bug
>          Components: Table API & SQL
>    Affects Versions: 1.3.2
>            Reporter: Rong Rong
>            Assignee: Timo Walther
>
> UDF is using FlinkTypeFactory to infer operand type while UDTF does not go 
> through the same code path. This result in:
> {code:console}
> org.apache.flink.table.api.ValidationException: SQL validation failed. From 
> line 1, column 38 to line 1, column 44: No match found for function signature 
> func(<COMPOSITE(Row(f0: Integer, f1: String))>) 
> Caused by: org.apache.calcite.runtime.CalciteContextException: From line 1, 
> column 38 to line 1, column 44: No match found for function signature 
> func(<COMPOSITE(Row(f0: Integer, f1: String))>)
> {code}
> Please see github code for more info:
> https://github.com/walterddr/flink/blob/bug_report/flink-libraries/flink-table/src/test/scala/org/apache/flink/table/api/batch/sql/UDTFCompositeTypeTestFailure.scala



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to