May 31, 2017 at 9:37 am
when we get a store procedure output as -1 ?
May 31, 2017 at 10:17 am
[/quote]
Are you getting that output? How are you calling the procedure?
May 31, 2017 at 10:27 am
Actually one of my friend asked this question.
June 1, 2017 at 8:25 am
My best guess is that it means an error occurred. By default, a stored proc will return 0 (as the return code). So that's typically taken as meaning a "good" result. Thus it became common to use a negative number -- either for the return code or even the result set -- to show a "bad" result.
SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".
June 1, 2017 at 8:44 am
Sue
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply