Hi ..
I m using raiserror function in sql server stored procedure to print error message ...
and also I want to store this error message in c# .Net variables.
Query will look like ....
declare @err varchar(5)
select distinct * from Mytesttablebackup
set @err=@@error
if @err <>0
Raiserror('details not found',100,@err)
can i store this raiserror message in C# like
string mess="";
mess=raiserror;
If yess then how
Thanks..
Storing sql raiserror message in C# variables
1 Answer
Know the answer? Post it. Somebody with the same question will find it here.

Niladri BiswasRank #3,172 · 452 reputationPosted Jun 7, 2009, 8:05 PM EDT