You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "sunjincheng (JIRA)" <ji...@apache.org> on 2017/08/03 05:52:00 UTC
[jira] [Updated] (FLINK-7358) Add implicitly converts support for
User-defined function
[ https://issues.apache.org/jira/browse/FLINK-7358?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
sunjincheng updated FLINK-7358:
-------------------------------
Description:
Currently if user defined a UDF as follows:
{code}
object Func extends ScalarFunction {
def eval(a: Int, b: Long): String = {
...
}
}
{code}
And if the table schema is (a: Int, b: int, c: String), then we can not call the UDF `Func('a, 'b)`. So
I want add implicitly converts when we call UDF. The implicitly convert rule is:
BYTE_TYPE_INFO -> SHORT_TYPE_INFO->INT_TYPE_INFO-> LONG_TYPE_INFO -> FLOAT_TYPE_INFO->DOUBLE_TYPE_INFO
*Note:
In this JIRA. only for TableAPI, And SQL will be fixed in https://issues.apache.org/jira/browse/CALCITE-1908.*
What do you think? [~fhueske]
was:
Currently if user defined a UDF as follows:
{code}
object Func extends ScalarFunction {
def eval(a: Int, b: Long): String = {
...
}
}
{code}
And if the table schema is (a: Int, b: int, c: String), then we can not call the UDF `Func('a, 'b)`. So
I want add implicitly converts when we call UDF.
*Note:
In this JIRA. only for TableAPI, And SQL will be fixed in https://issues.apache.org/jira/browse/CALCITE-1908.*
What do you think? [~fhueske]
> Add implicitly converts support for User-defined function
> ----------------------------------------------------------
>
> Key: FLINK-7358
> URL: https://issues.apache.org/jira/browse/FLINK-7358
> Project: Flink
> Issue Type: Improvement
> Components: Table API & SQL
> Reporter: sunjincheng
> Assignee: sunjincheng
>
> Currently if user defined a UDF as follows:
> {code}
> object Func extends ScalarFunction {
> def eval(a: Int, b: Long): String = {
> ...
> }
> }
> {code}
> And if the table schema is (a: Int, b: int, c: String), then we can not call the UDF `Func('a, 'b)`. So
> I want add implicitly converts when we call UDF. The implicitly convert rule is:
> BYTE_TYPE_INFO -> SHORT_TYPE_INFO->INT_TYPE_INFO-> LONG_TYPE_INFO -> FLOAT_TYPE_INFO->DOUBLE_TYPE_INFO
> *Note:
> In this JIRA. only for TableAPI, And SQL will be fixed in https://issues.apache.org/jira/browse/CALCITE-1908.*
> What do you think? [~fhueske]
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)