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

Jingsong Lee commented on FLINK-15579:
--------------------------------------

Hi [~eric.zheng], I changed the title to "Support UpsertStreamTableSink on 
Blink batch mode". FYI.

> Can not use jdbc connector on Blink batch mode 
> -----------------------------------------------
>
>                 Key: FLINK-15579
>                 URL: https://issues.apache.org/jira/browse/FLINK-15579
>             Project: Flink
>          Issue Type: Improvement
>          Components: Table SQL / Planner
>    Affects Versions: 1.9.0, 1.9.1
>            Reporter: Shu Li Zheng
>            Assignee: Shu Li Zheng
>            Priority: Major
>
> Because JDBCTableSourceSinkFactory.createStreamTableSink() create 
> JDBCUpsertTableSink. But BatchExecSink can not work with 
> UpsertStreamTableSink.
> {code:scala}
>   override protected def translateToPlanInternal(
>       planner: BatchPlanner): Transformation[Any] = {
>     val resultTransformation = sink match {
>       case _: RetractStreamTableSink[T] | _: UpsertStreamTableSink[T] =>
>         throw new TableException("RetractStreamTableSink and 
> UpsertStreamTableSink is not" +
>           " supported in Batch environment.")
> {code}
> DDL like:
> CREATE TABLE USER_RESULT(
> NAME VARCHAR,
> CITY VARCHAR,
> SCORE BIGINT
> ) WITH (
> 'connector.type' = 'jdbc',
> 'connector.url' = '',
> 'connector.table' = '',
> 'connector.driver' = 'com.mysql.cj.jdbc.Driver',
> 'connector.username' = 'root',
> 'connector.password' = '',
> 'connector.write.flush.interval' = '1s')



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

Reply via email to