We have a legacy application which sends messages to the application using raiseerror
like,
raiserror('A generic error',16,1)
Now I need to know how to catch these messages in C#,
catch (SqlException ex)
{
//
}
Currently SqlException
has everything including custom messages. I wanna filter that.