DESCRIBE DYNAMIC TABLE

描述 动态表 中的列。

DESCRIBE 可以缩写为 DESC。

另请参阅:

CREATE DYNAMIC TABLEALTER DYNAMIC TABLEDROP DYNAMIC TABLESHOW DYNAMIC TABLES

语法

DESC[RIBE] DYNAMIC TABLE <name>
Copy

参数

name

指定要描述的动态表的标识符。如果标识符包含空格或特殊字符,则整个字符串必须放在双引号内。放在双引号内的标识符也区分大小写。

访问控制要求

用于执行此操作的 角色 必须至少具有以下 权限

权限

对象

备注

SELECT

要描述的动态表。

如果您没有 MONITOR 权限,则部分元数据会被隐藏。有关更多信息,请参阅 查看动态表元数据的权限

The USAGE privilege on the parent database and schema are required to perform operations on any object in a schema. Note that a role granted any privilege on a schema allows that role to resolve the schema. For example, a role granted CREATE privilege on a schema can create objects on that schema without also having USAGE granted on that schema.

有关创建具有指定权限集的自定义角色的说明,请参阅 创建自定义角色

有关对 安全对象 执行 SQL 操作的相应角色和权限授予的一般信息,请参阅 访问控制概述

使用说明

  • 要DESCRIBE动态表,您必须使用对表具有 MONITOR 权限的角色。

  • 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.

    The output column names for this command are generated in lowercase. If you consume a result set from this command with the pipe operator or the RESULT_SCAN function, use double-quoted identifiers for the column names in the query to ensure that they match the column names in the output that was scanned. For example, if the name of an output column is type, then specify "type" for the identifier.

示例

描述 my_dynamic_table 中的列:

DESC DYNAMIC TABLE my_dynamic_table;
Copy
语言: 中文