select * from ( SELECT row_number() over(order by BogusRowOrder) as RowNum, count(*) over() as RowCnt, * from ( SELECT 1 as BogusRowOrder, * FROM [AdventureWorks].[Production].[Product] ) as a ) as b where RowNum > RowCnt-50
select * from Employee where empid not in ( select top ( (select count(*) from Employee) - 5 ) empid from Employee )
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)