自动生成 序列号id
2005用 SELECT ROW_NUMBER() OVER (order by col2 ) AS COL,col1,col2 from tb1 2000用 select col= identity(int,1,1),col1,col2 into # from tbl select * from # drop table #
本篇文章来自<A href='http://www.soidc.net'>IDC专家网</a> 原文链接:http://www.soidc.net/discuss/31/040101/00/502100_1.html