Hi,
I'm trying to write a new storedproc to call some existing code in a released application.
The original code was written to be called by a .NET application and had RAISERROR statements as follows:
RAISERROR ('blah %s', 10, 1, @variables) WITH SETERROR
Ideally I'd like to piggy back on this code and be able to catch the RAISERROR in my storedproc, but since it doesn't have a msg-id I can't seem to get the error from sysmessages.
Can anyone tell me how to catch this error in my code?
Thanks,
Paul.
ps: It's SQL Server 2000 and I can't change the underlying storedproc.
I'm trying to write a new storedproc to call some existing code in a released application.
The original code was written to be called by a .NET application and had RAISERROR statements as follows:
RAISERROR ('blah %s', 10, 1, @variables) WITH SETERROR
Ideally I'd like to piggy back on this code and be able to catch the RAISERROR in my storedproc, but since it doesn't have a msg-id I can't seem to get the error from sysmessages.
Can anyone tell me how to catch this error in my code?
Thanks,
Paul.
ps: It's SQL Server 2000 and I can't change the underlying storedproc.