hutiefang76 opened a new pull request, #703:
URL: https://github.com/apache/doris-flink-connector/pull/703

   # Proposed changes
   
   ## Problem Summary:
   When an auto partition column is already a primary key, `DorisSchemaFactory` 
emits it twice in both the column definitions and `UNIQUE KEY` clause. This 
produces invalid CREATE TABLE SQL for an ordinary partitioned primary-key table.
   
   Declare an existing key column once, retain its key position and NOT NULL 
constraint, and append the partition column only when it is outside the key 
list. Keep the caller's schema unchanged.
   
   Regression tests cover partition columns inside/outside the primary key and 
repeated generation without schema mutation. The factory tests passed (12 
tests), and neighboring table configuration tests passed (2 tests) with the 
Flink 1 profile, Checkstyle and Spotless enabled on JDK 17. No live Doris 
cluster was used.
   
   ## Checklist(Required)
   1. Does it affect the original behavior: Yes, invalid duplicate declarations 
are removed.
   2. Has unit tests been added: Yes
   3. Has document been added or modified: No Need
   4. Does it need to update dependencies: No
   5. Are there any changes that cannot be rolled back: No
   
   ## Further comments
   AI assistance: DeepSeek assisted implementation and initial review; the 
final patch and test evidence were checked before submission.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to