注释数据迁移的更新数据sql

This commit is contained in:
wangzhijiang
2023-04-17 17:39:58 +08:00
parent 827ea7152d
commit 5484366813
+96 -96
View File
@@ -507,102 +507,102 @@ INSERT INTO `sys_dict_item`(`id`, `dict_id`, `item_text`, `item_value`, `descrip
INSERT INTO `sys_dict_item`(`id`, `dict_id`, `item_text`, `item_value`, `description`, `sort_order`, `status`, `create_by`, `create_time`, `update_by`, `update_time`, `is_tag_dict`, `is_read_only`, `attribute_type`, `del_flag`, `en_name`) VALUES ('1524311354002771970', '1524311122804346881', '实验通过', 'Test passed', '实验通过', 3, 1, 'admin', '2022-05-11 16:52:02', NULL, NULL, NULL, NULL, NULL, '0', 'Test passed');
-- 初始化生产环境,设计符合性流程状态为空的数据 处理成 清单待发布 2023-4-10 未同步生产环境
UPDATE `project_laws_inventory`
SET `design_flow_status` = 'List to be released'
WHERE
`id` IN ( SELECT temp.id FROM ( SELECT id FROM project_laws_inventory WHERE design_flow_status IS NULL ) temp );
-- 初始化生产环境,验证符合性流程状态为空的数据 处理成 清单待发布 2023-4-10 未同步生产环境
UPDATE `project_laws_inventory`
SET `verify_flow_status` = 'List to be released'
WHERE
`id` IN (SELECT temp.id FROM (SELECT id FROM project_laws_inventory WHERE verify_flow_status IS NULL ) temp);
-- *********************************************** 法规相关历史数据处理sql *********************************************************
-- 以下sql需要按照顺序执行,否则会出问题。 2023-04-11 未同步生产环境
-- 处理 法规清单确认 待确认状态的数据sql
UPDATE `project_laws_inventory` SET
`design_flow_status` = 'List to be checked',
`verify_flow_status` = 'List to be checked'
where id in (
SELECT temp.id FROM (
SELECT
id
FROM
project_laws_inventory
WHERE inventory_affirm_status = 'List to confirm'
) temp
);
-- 处理待办中心-流程历史,之前的符合性流程数据sql。
-- 1.将之前符合性流程的 发起人审核节点, 处理结果为 符合、不涉及的数据,更新为通过(现在法规工程师审核的时候 处理结果是通过)
update process_history set
operator_result = 'Adopt'
where id in (
SELECT temp.id FROM (
select
id
from
process_history
where task_definition_key = 'fqrsh' and operator_result in ('Compliance','NA')
) temp
);
-- 2.将之前符合性流程的 发起人审核节点,修改为 法规工程师审核节点
update process_history set
task_definition_key = 'fggcssh'
where id in (
SELECT temp.id FROM (
select
id
from
process_history
where task_definition_key = 'fqrsh'
) temp
);
-- 3.将之前符合性流程的 责任人处理任务 节点,修改为 符合性确认节点
update process_history set
task_definition_key = 'zrrtjjfw'
where id in (
SELECT temp.id FROM (
select
id
from
process_history
where task_definition_key = 'zrrclrw'
) temp
);
-- 处理待办中心-流程节点明细,之前的符合性流程节点任务节点keysql
-- 1.将之前符合性流程的 发起人审核节点,修改为 法规工程师审核节点
update process_info_detail set
task_definition_key = 'fggcssh'
where id in (
SELECT temp.id FROM (
select
id
from
process_info_detail
where task_definition_key = 'fqrsh' and `status` = 'haveDone'
) temp
);
-- 2.将之前符合性流程的 责任人处理任务 节点,修改为 符合性确认节点
update process_info_detail set
task_definition_key = 'zrrtjjfw'
where id in (
SELECT temp.id FROM (
select
id
from
process_info_detail
where task_definition_key = 'zrrclrw' and `status` = 'haveDone'
) temp
);
# -- 初始化生产环境,设计符合性流程状态为空的数据 处理成 清单待发布 2023-4-10 未同步生产环境
# UPDATE `project_laws_inventory`
# SET `design_flow_status` = 'List to be released'
# WHERE
# `id` IN ( SELECT temp.id FROM ( SELECT id FROM project_laws_inventory WHERE design_flow_status IS NULL ) temp );
#
#
# -- 初始化生产环境,验证符合性流程状态为空的数据 处理成 清单待发布 2023-4-10 未同步生产环境
# UPDATE `project_laws_inventory`
# SET `verify_flow_status` = 'List to be released'
# WHERE
# `id` IN (SELECT temp.id FROM (SELECT id FROM project_laws_inventory WHERE verify_flow_status IS NULL ) temp);
#
#
# -- *********************************************** 法规相关历史数据处理sql *********************************************************
# -- 以下sql需要按照顺序执行,否则会出问题。 2023-04-11 未同步生产环境
# -- 处理 法规清单确认 待确认状态的数据sql
# UPDATE `project_laws_inventory` SET
# `design_flow_status` = 'List to be checked',
# `verify_flow_status` = 'List to be checked'
# where id in (
# SELECT temp.id FROM (
# SELECT
# id
# FROM
# project_laws_inventory
# WHERE inventory_affirm_status = 'List to confirm'
# ) temp
# );
#
#
# -- 处理待办中心-流程历史,之前的符合性流程数据sql。
# -- 1.将之前符合性流程的 发起人审核节点, 处理结果为 符合、不涉及的数据,更新为通过(现在法规工程师审核的时候 处理结果是通过)
# update process_history set
# operator_result = 'Adopt'
# where id in (
# SELECT temp.id FROM (
# select
# id
# from
# process_history
# where task_definition_key = 'fqrsh' and operator_result in ('Compliance','NA')
# ) temp
# );
#
# -- 2.将之前符合性流程的 发起人审核节点,修改为 法规工程师审核节点
# update process_history set
# task_definition_key = 'fggcssh'
# where id in (
# SELECT temp.id FROM (
# select
# id
# from
# process_history
# where task_definition_key = 'fqrsh'
# ) temp
# );
#
# -- 3.将之前符合性流程的 责任人处理任务 节点,修改为 符合性确认节点
# update process_history set
# task_definition_key = 'zrrtjjfw'
# where id in (
# SELECT temp.id FROM (
# select
# id
# from
# process_history
# where task_definition_key = 'zrrclrw'
# ) temp
# );
#
# -- 处理待办中心-流程节点明细,之前的符合性流程节点任务节点keysql
# -- 1.将之前符合性流程的 发起人审核节点,修改为 法规工程师审核节点
# update process_info_detail set
# task_definition_key = 'fggcssh'
# where id in (
# SELECT temp.id FROM (
# select
# id
# from
# process_info_detail
# where task_definition_key = 'fqrsh' and `status` = 'haveDone'
# ) temp
# );
# -- 2.将之前符合性流程的 责任人处理任务 节点,修改为 符合性确认节点
# update process_info_detail set
# task_definition_key = 'zrrtjjfw'
# where id in (
# SELECT temp.id FROM (
# select
# id
# from
# process_info_detail
# where task_definition_key = 'zrrclrw' and `status` = 'haveDone'
# ) temp
# );
-- 认证清单,增加字段 2023-04-17 未同步生产环境