declare mycursor cursor scroll dynamic
for
select customerid,address from bin_retailcustomer where delflag = '0' and areaid = '' and address like '%十巷%'


open mycursor
declare @id bigint
declare @address varchar(50)
fetch next from mycursor into @id,@address
while(@@fetch_status = 0)
begin

update bin_retailcustomer set address = replace(@address,'十巷','10巷') where customerid = @id


fetch next from mycursor into @id,@address

end
close mycursor

 

 

Logo

汇聚全球AI编程工具,助力开发者即刻编程。

更多推荐