--批量修改货品分类、货品存放位置、货品规格、来往单位分类
ALTER
PROC BatchPerfect
@TableName NvarChar(50),
@ColumnName NvarChar(50),
@Code__ NvarChar(50),
@SelectID NvarChar(1000)
AS
Declare @SqlStr NvarChar(1200)
SET @SqlStr='Update '+@TableName+' Set '+@ColumnName+'=@Code Where [ID] IN('+@SelectID+')'
PRINT @SqlStr
EXEC SP_EXECUTESQL @SqlStr,N'@Code NvarChar(50)',@Code=@Code__
看不懂找联机帮助。谢谢