declare @int int set @int=0 select @int=@int+Gid from Expro_News print @int 转载于:https://www.cnblogs.com/wangdetian168/archive/2009/03/17/1414137.html