Hi,
Does anyone know if SQL Server has a @@ROWID variable or function that gives me the row number the query is on?
For exampe if I select 5 quiries from an employee table:
SELECT FirstName, LastName, Age, @@ROWID
it gives me
John, Smith, 40, 1
Jane, Doe, 34, 2
Josh, Cooper, 44, 3
keeps incrementing automatically when displaying each row
Bob