Di Wu created FLINK-38275:
-----------------------------
Summary: Doris Pipeline Sink cannot create a table when the
upstream has no primary key and the first column is String
Key: FLINK-38275
URL: https://issues.apache.org/jira/browse/FLINK-38275
Project: Flink
Issue Type: Improvement
Components: Flink CDC
Affects Versions: cdc-3.5.0
Reporter: Di Wu
If the upstream model lacks PrimaryKeys and the first column is a String, the
Doris Sink will identify the model as a duplicate and will not set keys. In
this case, an error message will be reported when creating the table: errCode =
2, detailMessage = String Type should not be used in key column[name].
Doris-Flink-Connector handles table creation.
https://github.com/apache/doris-flink-connector/blob/master/flink-doris-connector/src/main/java/org/apache/doris/flink/catalog/doris/DorisSchemaFactory.java#L226-L227
If the key is a String, the type is changed to Varchar(65535). Therefore, the
first key set here can be used as the table key.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)