ousoonerjoe
Programmer
I have a procedure that makes several updates/inserts based upon the data passed to it. There are no special Return Values/RecSets as it is now. The question i have is, Can a Stored Proc return the number of affected records?
For example:
Is this possible?
As always, any tips, comments, and/or suggestions are welcome. Thank you
"If I were to wake up with my head sewn to the carpet, I wouldn't be more surprised than I am right now.
For example:
Code:
CREATE PROCEDURE usp_Do_Something(@StartDate DATETIME)
AS
If @StartDate...
UPDATE Table1...
INSERT Table2...
ELSE
INSERT Table1...
INSERT Table2...
UPDATE Table3...
END
INSERT Table4...
UPDATE Table5...
RETURN [b][i]Number of records affected[/i][/b]
Is this possible?
As always, any tips, comments, and/or suggestions are welcome. Thank you
"If I were to wake up with my head sewn to the carpet, I wouldn't be more surprised than I am right now.