瀏覽代碼

data patch

Tony Kang 1 年之前
父節點
當前提交
cf42b908d9
共有 1 個文件被更改,包括 11 次插入0 次删除
  1. 11 0
      sql/update.sql

+ 11 - 0
sql/update.sql

@@ -61,3 +61,14 @@ ALTER TABLE `zh_role_rpt_rel`
 ADD COLUMN `business_id` VARCHAR(45) NULL AFTER `sid`,
 ADD INDEX `bz_idx` (`tender_id` ASC, `business_id` ASC);
 ;
+
+update zh_rpt_archive A
+set A.tender_id = (select tid from zh_stage B where B.id = A.stage_id)
+where (A.stage_id is not null) && (A.stage_id > 0)
+;
+
+update zh_rpt_archive_encryption A
+set A.tender_id = (select tid from zh_stage B where B.id = A.stage_id)
+where (A.stage_id is not null) && (A.stage_id > 0)
+;
+