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

Jark Wu commented on FLINK-22378:
---------------------------------

This is a good question. A workaround for this can be fix the return type in 
{{SchemaResolver}}, or have a special {{CallContext}} (e.g. 
{{WatermarkCallContext}}) for watermark expressions which have access to the 
rowtime field (the column specified by {{WATERMARK FOR <rowtime>}}).

> Type mismatch when declaring SOURCE_WATERMARK on TIMESTAMP_LTZ column
> ---------------------------------------------------------------------
>
>                 Key: FLINK-22378
>                 URL: https://issues.apache.org/jira/browse/FLINK-22378
>             Project: Flink
>          Issue Type: Sub-task
>          Components: Table SQL / API
>            Reporter: Timo Walther
>            Priority: Major
>
> The following schema cannot be resolved currently:
> {code}
> Schema.newBuilder()
>     .columnByMetadata("rowtime", DataTypes.TIMESTAMP_LTZ(3))
>     .watermark("rowtime", "SOURCE_WATERMARK()")
>     .build()
> {code}
> It leads to:
> {code}
> The watermark output type TIMESTAMP(3) is different from input time filed 
> type TIMESTAMP_LTZ(3).
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to