Carlo Romagnano (4/16/2009)
Correct answer is 1-25:exec sp_helptext sp_addmessage
in the output search for @severity and you'll find this piece of code that is the law.
-- Valid severity range for user defined messges is 1 to 25.
if @severity not between 1 and 25
begin
raiserror(15041,-1,-1)
return (1)
end
I have read (somewhere) that users can create messages with error severity from 1-25. However, the database engine itself can send a severity of 0. Therefore, the correct answer is 0-25.
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes