sys.server_sql_modules (Transact-SQL)sys.server_sql_modules (Transact-SQL)

适用对象: yesSQL ServeryesAzure SQL 数据库noAzure SQL 数据仓库no并行数据仓库APPLIES TO: yesSQL Server noAzure SQL Database noAzure SQL Data Warehouse noParallel Data Warehouse

包含类型为 TR 的服务器级别触发器的 SQL 模块设置。Contains the set of SQL modules for server-level triggers of type TR. 可将此关系与 sys.server_triggers 联接。You can join this relation to sys.server_triggers. 元组 (object_id) 是关系键。The tuple (object_id) is the key of the relation.

列名Column Name 数据类型Data Type 描述Description
object_idobject_id intint 这是返回给定义该模块的服务器级别触发器的 FOREIGN KEY 引用。This is a FOREIGN KEY reference back to the server-level trigger where this module is defined.
定义definition nvarchar(max)nvarchar(max) 定义此模块的 SQL 文本。SQL text that defines this module.

NULL = 加密。NULL = Encrypted.
uses_ansi_nullsuses_ansi_nulls bitbit 模块是通过将 ANSI NULLS 设置选项设置为 ON 而创建的。Module was created with ANSI NULLS set option set to ON.
uses_quoted_identifieruses_quoted_identifier bitbit 模块是通过将 QUOTED IDENTIFIER 设置选项设置为 ON 而创建的。Module was created with QUOTED IDENTIFIER set option set to ON.
execute_as_principal_idexecute_as_principal_id intint EXECUTE AS 服务器主体的 ID。ID of the EXECUTE AS server principal.

默认情况下或在 EXECUTE AS CALLER 情况下,值为 NULL。NULL by default or if EXECUTE AS CALLER

指定主体 if 的 ID 执行 AS SELF EXECUTE AS 主体-2 = EXECUTE AS OWNER。ID of the specified principal if EXECUTE AS SELF EXECUTE AS principal-2 = EXECUTE AS OWNER.

权限Permissions

目录视图中仅显示用户拥有的安全对象的元数据,或用户对其拥有某些权限的安全对象的元数据。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

目录视图 (Transact-SQL)Catalog Views (Transact-SQL)