[
https://issues.apache.org/jira/browse/FLINK-41478?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18145248#comment-18145248
]
Yuepeng Pan commented on FLINK-41478:
-------------------------------------
Merged into release-2.4(2.4.0) via: eec4326f928f472bedcaddae7f4dde63846fbc71
Merged into master(2.5.0) via: 9efb123c6131002d4001dede35d9284f9cb1919c
> Change the default of table.exec.sink.require-on-conflict to false
> ------------------------------------------------------------------
>
> Key: FLINK-41478
> URL: https://issues.apache.org/jira/browse/FLINK-41478
> Project: Flink
> Issue Type: Improvement
> Components: Table SQL / Planner
> Reporter: Gustavo de Morais
> Assignee: Gustavo de Morais
> Priority: Major
> Labels: pull-request-available
> Fix For: 2.4.0, 2.5.0
>
>
> Since 2.3, a query fails at planning time when its upsert key differs from
> the sink's primary key and it has no ON CONFLICT clause
> ({{table.exec.sink.require-on-conflict}} defaults to {{true}}). This breaks
> queries that ran fine on 2.2, fails queries the planner can't prove correct
> because upsert key inference is conservative, and leaves CTAS, RTAS and
> CREATE MATERIALIZED TABLE without a way to set the clause.
> We should change the default to {{false}}, so a missing ON CONFLICT clause
> behaves like ON CONFLICT DO DEDUPLICATE as before 2.3. The clause itself
> stays unchanged and users can still opt in to requiring it.
> Discussion: https://lists.apache.org/thread/46vofq8qp1lshr3j6lnlycb0fdxfm7t4
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)