sys.sp_syspolicy_set_log_on_success

general
#stored-procedure

Description

Specifies whether successful policy evaluations are logged in the Policy History log for Policy- Based Management. Determines whether successful policy evaluations are logged. one of the following values: - Successful policy evaluations aren’t logged. - Successful policy evaluations are logged. in the context of the system database. , only failed policy evaluations are logged.

Syntax

sp_syspolicy_set_log_on_success

Remarks

Specifies whether successful policy evaluations are logged in the Policy History log for Policy-

Based Management.

Determines whether successful policy evaluations are logged.

, and can be

one of the following values:

(success) or

You must run

in the context of the

system database.

, only failed policy evaluations are logged.

Examples

Example 1

EXECUTE msdb.dbo.sp_syspolicy_set_log_on_success @
value
= 1;
GO