ChengDa_English/DataBase/版本日志/SGGLDB_CD_V2023-07-23-001.sql

28 lines
2.0 KiB
SQL
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.


update WBS_Breakdown
set BreakdownCode='2.2.4'
where '2.2.4.'=BreakdownCode
select * from ( SELECT BreakdownCode,CHARINDEX('.',BreakdownCode,(LEN(BreakdownCode)-3)) a,
SUBSTRING( BreakdownCode ,CHARINDEX('.',BreakdownCode,(LEN(BreakdownCode)-2))+1,2) indexs
FROM WBS_Breakdown ) aa
where indexs like '%.%'
update WBS_BreakdownProject
set SortIndex=SUBSTRING( BreakdownCode ,CHARINDEX('.',BreakdownCode,(LEN(BreakdownCode)-2))+1,2)
update WBS_BreakdownProject
set BreakdownCode='2.2.4'
where '2.2.4.'=BreakdownCode
select * from ( SELECT BreakdownCode,CHARINDEX('.',BreakdownCode,(LEN(BreakdownCode)-3)) a,
SUBSTRING( BreakdownCode ,CHARINDEX('.',BreakdownCode,(LEN(BreakdownCode)-2))+1,2) indexs
FROM WBS_BreakdownProject ) aa
where indexs like '%.%'
update WBS_BreakdownProject
set SortIndex=SUBSTRING( BreakdownCode ,CHARINDEX('.',BreakdownCode,(LEN(BreakdownCode)-2))+1,2)