SHOW REFERENCES¶
列出清单文件中为应用程序定义的引用以及使用者与该应用程序关联的引用。
语法
参数
name指定应用程序的名称。
访问控制要求
A role used to execute this operation must have the following privileges at a minimum:
| 权限 | 对象 | 备注 |
|---|---|---|
| OWNERSHIP | 应用程序 | 要运行此命令,您必须拥有应用程序的所有权权限。 |
For instructions on creating a custom role with a specified set of privileges, see Creating custom roles.
For general information about roles and privilege grants for performing SQL actions on securable objects, see Overview of Access Control.
输出
此命令显示有关为应用程序定义的引用的以下信息:
| Column | Description |
|---|---|
| name | The name of the reference. |
| label | The label of the reference as specified in the manifest file. |
| description | A description of the reference and what it does. |
| privileges | The privileges that the reference requires. Refer to Object types and privileges that a reference can contain for the list of privileges that a reference can require for an object. |
| object_type | The type of object associated with the reference. Refer to Object types and privileges that a reference can contain for a list of the supported objects for a reference. |
| multi-valued | Indicates if the reference requires more than one type of object. |
| object_name | 使用者将对象与应用程序关联后,由引用指定的对象的名称。 |
| schema_name | 与此引用关联的对象架构的名称;如果没有关联对象或关联对象是账户对象,则为 NULL。 |
| database_name | 与此引用关联的对象的数据库名称,如果满足以下条件之一,则为 NULL:
|
| alias | 唯一标识对象引用的名称,包括对象名称、范围和权限。 |
使用说明
- The command doesn’t require a running warehouse to execute.
- The command only returns objects for which the current user’s current role has been granted at least one access privilege.
- The MANAGE GRANTS access privilege implicitly allows its holder to see every object in the account. By default, only the account administrator (users with the ACCOUNTADMIN role) and security administrator (users with the SECURITYADMIN role) have the MANAGE GRANTS privilege.
-
To post-process the output of this command, you can use the pipe operator (
->>) or the RESULT_SCAN function. Both constructs treat the output as a result set that you can query.For example, you can use the pipe operator or RESULT_SCAN function to select specific columns from the SHOW command output or filter the rows.
When you refer to the output columns, use double-quoted identifiers for the column names. For example, to select the output column
type, specifySELECT "type".You must use double-quoted identifiers because the output column names for SHOW commands are in lowercase. The double quotes ensure that the column names in the SELECT list or WHERE clause match the column names in the SHOW command output that was scanned.