创建临时表的时候不能添加一个自增列
set @sql = N'select no=identity(int,1,1),id,stepCode,lcType,clgclj,zhcl_sj into ##ls_jtsjtable from ' + @tblName + N' where isEnd=0 and isdelete=0'
exec sp_executesql @sql
这里no=identity(int,1,1)是我向要的连续编号的NO,id是原来的表中的自增列,可是提示说已经以后了ID,不可在添加NO,有什么办法解决吗?