182764125216
182764125216

Reputation: 956

ROW_NUMBER() in linqpad

I am trying to get row numbers to show up in my LINQPad query.

SELECT ROW_NUMBER() OVER(ORDER BY TestNum) AS 'Row Number', TestNum
FROM Test

I get:

Error 195: 'ROW_NUMBER' is not a recognized function name.

I also tried
ROWNUM()
{ fn ROW_NUMBER() }
{ fn ROWNUM() }
among others...

I am using LINQPad v4.20

Thanks.

Upvotes: 1

Views: 446

Answers (1)

recursive
recursive

Reputation: 86174

What version of SQL Server are you using? ROW_NUMBER() is not available in SQL Server 2000 or earlier.

Upvotes: 1

Related Questions