How to retrieve SQL Agent failsafe operator email?
2
votes
2
answers
97
views
I want to find the email of the failsafe SQL Server Agent operator.
Usually I use this query :
DECLARE @TARGET nvarchar(255);
IF @OPERATOR_CONTACT IS NULL
exec master.dbo.xp_instance_regread
N'HKEY_LOCAL_MACHINE',
N'SOFTWARE\Microsoft\MSSQLServer\SQLServerAgent',
N'AlertFailSafeEmailAddress',
@param = @TARGET OUT,
@no_output = N'no_output';
But this query does not work on all SQL Server instances...
Did anyone has a more generic query to obtain this information ?
Asked by SQLpro
(550 rep)
Mar 27, 2024, 08:32 AM
Last activity: Jun 26, 2025, 08:42 AM
Last activity: Jun 26, 2025, 08:42 AM