top问题
select top 10 id from ( select * from aa_tb order by birthday desc ) as a where id not in (select top 0 id from aa_tb)
提示“除非同时指定了 TOP,否则 ORDER BY 子句在视图、内嵌函数、派生表和子查询中无效。”
[解决办法]
select top 10 id from aa_tb a where id not in (select top 0 id from aa_tb order by birthday desc ) order by birthday desc