lordk911 commented on issue #12561: URL: https://github.com/apache/dolphinscheduler/issues/12561#issuecomment-1293306335
- the root case is **https://github.com/apache/dolphinscheduler/issues/8790#issuecomment-1098620438** - the [https://dolphinscheduler.apache.org/zh-cn/docs/release/faq.html](url) about : `Q:Update process definition error: Duplicate key TaskDefinition` **method can't resolve this scenario** two way to resove this issue maybe : 1. https://github.com/apache/dolphinscheduler/blob/873cbc75c6dc9da16e3e1e61abb751fab8fd009f/dolphinscheduler-server/src/main/java/org/apache/dolphinscheduler/server/utils/DependentExecute.java#L142 **taskRelations build from t_ds_process_definition not t_ds_process_task_relation_log** 2. join t_ds_process_task_relation_log and t_ds_process_definition get the difference set from t_ds_process_task_relation_log and delete. sql like : ``` DELETE FROM t_ds_process_task_relation_log WHERE id IN ( SELECT rl.id FROM dolphinscheduler.t_ds_process_task_relation_log rl LEFT JOIN dolphinscheduler.t_ds_process_task_relation r ON rl.process_definition_code = r.process_definition_code AND rl.process_definition_version = r.process_definition_version AND rl.pre_task_code = r.pre_task_code AND rl.pre_task_version = r.pre_task_version AND rl.post_task_code = r.post_task_code AND rl.post_task_version = r.post_task_version WHERE r.id IS NULL AND rl.process_definition_code=3755309715595 AND rl.process_definition_version=1 ) ``` @JinyLeeChina @caishunfeng @SbloodyS -- 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]
