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

Jark Wu commented on FLINK-24116:
---------------------------------

The check on Kafka insert-only source is that we found many users used it by 
mistake. Actually, it's almost impossible to guarantee the uniqueness of a 
primary key on Kafka insert-only source. This can result in wrong result when 
planner use the primary key for some optimziation. 

> PRIMARY KEY declaration on insert-only table is not validated globally
> ----------------------------------------------------------------------
>
>                 Key: FLINK-24116
>                 URL: https://issues.apache.org/jira/browse/FLINK-24116
>             Project: Flink
>          Issue Type: Bug
>          Components: Table SQL / API
>            Reporter: Timo Walther
>            Priority: Major
>
> In the regular Kafka connector, we validate that a primary key is not defined 
> on an insert-only table source:
> https://github.com/apache/flink/pull/13850/commits/c1d4dc89fa629e0f04102e7ab2fa94984cd98218
> However, this should be validated for every connector because it is confusing 
> if it works for others. We should validate this in the planner instead.



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

Reply via email to