sys.dm_audit_actions (Transact-SQL)sys.dm_audit_actions (Transact-SQL)

适用于:Applies to: 是SQL ServerSQL Server(所有支持的版本)yesSQL ServerSQL Server (all supported versions) 是Azure SQL 数据库Azure SQL DatabaseYesAzure SQL 数据库Azure SQL Database 是Azure SQL 托管实例Azure SQL Managed InstanceYesAzure SQL 托管实例Azure SQL Managed Instance 是Azure Synapse AnalyticsAzure Synapse AnalyticsyesAzure Synapse AnalyticsAzure Synapse Analytics适用于:Applies to: 是SQL ServerSQL Server(所有支持的版本)yesSQL ServerSQL Server (all supported versions) 是Azure SQL 数据库Azure SQL DatabaseYesAzure SQL 数据库Azure SQL Database 是Azure SQL 托管实例Azure SQL Managed InstanceYesAzure SQL 托管实例Azure SQL Managed Instance 是Azure Synapse AnalyticsAzure Synapse AnalyticsyesAzure Synapse AnalyticsAzure Synapse Analytics

为可在审核日志中报告的每项审核操作以及可配置为 SQL ServerSQL Server Audit 一部分的每个审核操作组返回一行。Returns a row for every audit action that can be reported in the audit log and every audit action group that can be configured as part of SQL ServerSQL Server Audit. 有关审核的详细信息 SQL ServerSQL Server ,请参阅 SQL Server audit (数据库引擎)For more information about SQL ServerSQL Server Audit, see SQL Server Audit (Database Engine).

列名称Column name 数据类型Data type 说明Description
action_idaction_id varchar(4)varchar(4) 审核操作的 ID。ID of the audit action. 与写入每个审核记录的 action_id 值相关。Related to the action_id value written to each audit record. 可以为 Null。Is nullable. 对于审核组,为 NULL。NULL for audit groups.
action_in_logaction_in_log bitbit 指示是否可以将操作写入审核日志。Indicates whether an action can be written to an audit log. 值如下:Values are as follows:

1 = 是1 = Yes

0 = 否0 = No
namename sysnamesysname 审核操作或审核组的名称。Name of the audit action or action group. 不可为 null。Is not nullable.
class_descclass_desc nvarchar(120)nvarchar(120) 应用审核操作对象的类的名称。The name of the class of the object that the audit action applies to. 可以为任何 Server、Database 或 Schema 作用域对象之一,但是不包括 Schema 对象。Can be any one of the Server, Database, or Schema scope objects, but does not include Schema objects. 不可为 null。Is not nullable.
parent_class_descparent_class_desc nvarchar(120)nvarchar(120) class_desc 所描述对象的父类的名称。Name of the parent class for the object described by class_desc. 如果 class_desc 为 Server,则为 NULL。Is NULL if the class_desc is Server.
covering_parent_action_namecovering_parent_action_name nvarchar(120)nvarchar(120) 包含此行中所述的审核操作的审核操作或审核组的名称。Name of the audit action or audit group that contains the audit action described in this row. 该名称用于创建操作和覆盖操作的层次结构。This is used to create a hierarchy of actions and covering actions. 可以为 Null。Is nullable.
configuration_levelconfiguration_level **nvarchar (10) **nvarchar(10) 指示此行中指定的操作或操作组在“组”或“操作”级别是可配置的。Indicates that the action or action group specified in this row is configurable at the Group or Action level. 如果操作不可配置,则为 NULL。Is NULL if the action is not configurable.
containing_group_namecontaining_group_name nvarchar(120)nvarchar(120) 包含指定操作的审核组的名称。The name of the audit group that contains the specified action. 如果名称中的值为组,则为 NULL。Is NULL if the value in name is a group.

权限Permissions

此视图对公共可见。This view is visible to the public.

目录视图中仅显示用户拥有的安全对象的元数据,或用户对其拥有某些权限的安全对象的元数据。The visibility of the metadata in catalog views is limited to securables that a user either owns or on which the user has been granted some permission... 有关详细信息,请参阅 Metadata Visibility ConfigurationFor more information, see Metadata Visibility Configuration.

另请参阅See Also

CREATE SERVER AUDIT (Transact-SQL) CREATE SERVER AUDIT (Transact-SQL)
ALTER SERVER AUDIT (Transact-SQL) ALTER SERVER AUDIT (Transact-SQL)
DROP SERVER AUDIT (Transact-SQL) DROP SERVER AUDIT (Transact-SQL)
CREATE SERVER AUDIT SPECIFICATION (Transact-SQL) CREATE SERVER AUDIT SPECIFICATION (Transact-SQL)
ALTER SERVER AUDIT SPECIFICATION (Transact-SQL) ALTER SERVER AUDIT SPECIFICATION (Transact-SQL)
DROP SERVER AUDIT SPECIFICATION (Transact-SQL) DROP SERVER AUDIT SPECIFICATION (Transact-SQL)
CREATE DATABASE AUDIT SPECIFICATION (Transact-SQL) CREATE DATABASE AUDIT SPECIFICATION (Transact-SQL)
ALTER DATABASE AUDIT SPECIFICATION (Transact-SQL) ALTER DATABASE AUDIT SPECIFICATION (Transact-SQL)
DROP DATABASE AUDIT SPECIFICATION (Transact-SQL) DROP DATABASE AUDIT SPECIFICATION (Transact-SQL)
ALTER AUTHORIZATION (Transact-SQL) ALTER AUTHORIZATION (Transact-SQL)
sys.fn_get_audit_file (Transact-SQL) sys.fn_get_audit_file (Transact-SQL)
sys.server_audits (Transact-SQL) sys.server_audits (Transact-SQL)
sys.server_file_audits (Transact-SQL) sys.server_file_audits (Transact-SQL)
sys.server_audit_specifications (Transact-SQL) sys.server_audit_specifications (Transact-SQL)
sys.server_audit_specification_details (Transact-SQL) sys.server_audit_specification_details (Transact-SQL)
sys.database_audit_specifications (Transact-SQL) sys.database_audit_specifications (Transact-SQL)
sys.database_audit_specification_details (Transact-SQL) sys.database_audit_specification_details (Transact-SQL)
sys.dm_server_audit_status (Transact-SQL) sys.dm_server_audit_status (Transact-SQL)
sys.dm_audit_class_type_map (Transact-SQL) sys.dm_audit_class_type_map (Transact-SQL)
创建服务器审核和服务器审核规范Create a Server Audit and Server Audit Specification