DECLARE @AFFECT INT
declare @t table(name nvarchar(20),qy nvarchar(20),je int)
insert into @t
select N'产品一',N'北京',500
union all select N'产品一',N'上海',300
union all select N'产品二',N'北京',600
union all select N'产品三',N'上海',1000
union all select N'产品三',N'北京',8008
union all select N'产品四',N'上海',400
print @@ROWCOUNT
update @t set je = 200 where name =N'产品一'
SET @AFFECT=@@ROWCOUNT
print @AFFECT