SHOW REPLICATION GROUPS¶
Displays information about replication groups and failover groups.
- 列出此账户中的每个主要复制组或次要复制组或故障转移组。
- 列出其他账户中已针对复制到此账户启用的主复制组和故障转移组。
- 列出其他账户中链接到此账户中的组的辅助复制组和故障转移组。
语法
参数
account指定账户的标识符。
输出
该命令返回以下列:
| Column | Description |
|---|---|
region_group | Region group where the account is located. Note: this column is only visible to organizations that span multiple Region groups. |
snowflake_region | 账户所在的 Snowflake 区域。Snowflake 区域是云平台区域内与其他 Snowflake 区域隔离的独特位置。Snowflake 区域可以是多租户或单租户(对于 Virtual Private Snowflake 账户)。 |
created_on | Date and time replication or failover group was created. |
account_name | Name of the account. |
name | Name of the replication or failover group. |
type | Type of group. Valid values are REPLICATION or FAILOVER. |
comment | Comment string. |
is_primary | Indicates whether the replication or failover group is the primary group. |
primary | Name of the primary group. |
object_types | List of specified object types enabled for replication (and failover in the case of a FAILOVER group). |
allowed_integration_types | 为复制启用的集成类型列表。 Snowflake always includes this column in the output even if integrations were not specified in the CREATE <object> or ALTER <object> command. |
allowed_accounts | List of accounts enabled for replication and failover. |
organization_name | Name of your Snowflake organization. |
account_locator | Account locator in a region. |
replication_schedule | Scheduled interval for refresh; NULL if no replication schedule is set. |
secondary_state | Current state of scheduled refresh. Valid values are started or suspended. NULL if no replication schedule is set. |
next_scheduled_refresh | Date and time of the next scheduled refresh. |
owner | 对复制组或故障转移组具有 OWNERSHIP 权限的角色名称。如果复制组或故障转移组位于不同的区域,则为 NULL。 |
is_listing_auto_fulfillment_group | TRUE if the replication group is used for Cross-Cloud Auto-Fulfillment. FALSE otherwise. |
使用说明
-
Executing this command requires a role with any one of the following privileges on a replication group:
- MONITOR
- OWNERSHIP
- REPLICATE
-
The output of SHOW REPLICATION GROUPS includes groups of types
FAILOVERandREPLICATION.
- 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.
示例
List replication groups in myaccount1: