O número da linha é o servidor SQL

ROW_NUMBER() OVER (ORDER BY 'Column_Name' DESC) as ROW_NUMBER


select ROW_NUMBER() OVER(PARTITION BY WorkOrderID ORDER BY WorkOrderID ASC) 
    AS Row#, * from TableName
Comfortable Cassowary