Reputation: 53223
Is it possible to count how many rows returned by a stored-procedure which returns a simple table?
Upvotes: 1
Views: 403
Reputation: 432210
Return @@ROWCOUNT
as either an output parameter or second result set.
Or add another column to the one resultset using a COUNT..OVER construct
...
COUNT(*) OVER () AS RowCount
...
Or read it in the client code eg DataTable.Rows.Count
Upvotes: 5