You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Doris: key columns are mapped to PRIMARY KEY incorrectly and composite keys are lost #37541
The connector marks a column as PRIMARY KEY when SHOW FULL COLUMNS reports Key=YES. In Doris that flag covers:
the key columns of all models, including DUPLICATE KEY sort keys, which are not unique;
every column of an external table.
With more than one key column, the column-level constraint becomes None, NOT NULL is lost, and no table-level constraint is emitted.
To Reproduce
Create a UNIQUE KEY table with a composite key (region, user_id) and a DUPLICATE KEY table.
Run metadata ingestion.
The UNIQUE table has no table-level constraint and its key columns lose NOT NULL; the DUPLICATE table's first sort key column is marked PRIMARY KEY.
Expected behavior
Read TABLE_MODEL and TABLE_MODEL_KEY from information_schema.table_options. Emit a table-level PRIMARY KEY for UNIQUE (and AGGREGATE) models only, and keep NOT NULL on key columns.
Activity
Fixes open-metadata#37541: Doris primary keys follow the table model (o…