My Coding Hints
Wednesday, January 1, 2014
To fetch the Nth row in the table
SELECT * FROM ( SELECT *, ROW_NUMBER() OVER (ORDER BY (SELECT '')) AS RowIndex FROM #tmp12 ) T1
WHERE T1.RowIndex = (select count(*) from #tmp12)
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment