update 的一种用法
declare @aa int set @aa = 1update EWC_HT_Contract set ContractCode = a.ContractCode + cast (@aa as nvarchar(10)),@aa = @aa +1 from
(select ContractCode from ContractWHERE (MasterID = 1)
) as awhere MasterID = 2
SQL Server 2000 里面的通过记录修改另一条记录地方法,还可以修改序号。