摘要:
很少很少写存储过程,不行,得练练手才行。----创建一个存储过程create procedure updateExchangeGiftCount_produ as begindeclare @materialsnids int ----定义你需要的变量declare @count int declare youbiao cursor for ----定义游标,取出你要的变量值select ig.materialsnid,sum(GiftsCount) as giftcountfrom dbo.IG_ExchangeHistory as ehinner join dbo.IG_Exchange. 阅读全文