参考下: select top 50 id=identity(int,1,1) into # from sysobjects select *, totalnum=(select sum(id) from (select top 7 id from # where a.id>=id order by id desc) c) from # a
34,838
社区成员
254,632
社区内容
加载中
试试用AI创作助手写篇文章吧