I have an stored proc with code that looks like:
Begin
Begin try
Begin Tran
Commit
End try
Begin Catch
-- get the error values and write them to a log table by executing another stored proc
ROLLBACK
-- here is the problem: RAISERROR won't compile, even in a comment!
END CATCH
END
Please note the strangeness of this: RAISERROR won't compile (connection time out), even if it is in a comment!
Win XP XP3, SQL Server 2008 (SP1) and SSMS 2008 R2. It doesn't make sense: existing procs that used to compile using RAISERROR no longer do. Any ideas?