select IDENTITY(INT,1,1) AS 序号,* into #a1 from spkfkdjok
select 'XJPZ'+right('00000'+cast(xuhao as nvarchar(10)),5),* from spkfkdjok
本文转自 qvodnet 51CTO博客,原文链接:http://blog.51cto.com/bks2015/1857681
select IDENTITY(INT,1,1) AS 序号,* into #a1 from spkfkdjok
select 'XJPZ'+right('00000'+cast(xuhao as nvarchar(10)),5),* from spkfkdjok