SELECT Row_NUMBER() OVER (ORDER BY <your criteria>) as RowIndex, other fields FROM MyTable
Update
To add this as a field, you can:
UPDATE T SET T.Indexfield = X.RowIndex FROM MyTable T INNER JOIN (SELECT Row_NUMBER() OVER (ORDER BY <your criteria>) as RowIndex, other fields FROM MyTable) as X ON X.<field> = T.<Field>
source share