--sql 2000
select
序号 = (
count
(1)
from
tb
where
学号 < t.学号) + 1,学号 ,姓名
tb t
--sql 2005
序号 = row_number() over(
order
by
学号),学号 ,姓名