SHOW FAILOVER GROUPS

列出您账户中的主要和次要 故障转移组,以及与您的账户关联的其他账户中的故障转移组。

对于其他账户:

  • 列出为了复制和故障转移到此账户而启用的主要故障转移组。

  • 列出链接到此账户中的组的辅助故障转移组。

另请参阅:

CREATE FAILOVER GROUPALTER FAILOVER GROUPDROP FAILOVER GROUP

语法

SHOW FAILOVER GROUPS [ IN ACCOUNT <account> ]
Copy

参数

account

指定账户的标识符。账户名称是您的组织中的唯一标识符。有关账户名称的更多详细信息,请参阅 格式 1(首选):您所在组织的账户名称

使用说明

  • 执行此命令需要具有以下 :emph:` 任意一项 ` 故障转移组权限:

    • FAILOVER

    • MONITOR

    • OWNERSHIP

    • REPLICATE

  • SHOW FAILOVER GROUPS 的输出仅包含类型为 FAILOVER 的组。

  • 该命令不需要正在运行的仓库即可执行。

  • 该命令仅返回当前用户的当前角色已获授至少一项访问权限的对象。

  • MANAGE GRANTS 访问权限隐式允许其持有者查看账户中的每个对象。默认情况下,只有账户管理员(具有 ACCOUNTADMIN 角色的用户)和安全管理员(具有 SECURITYADMIN 角色的用户)才具有 MANAGE GRANTS 权限。

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

输出

该命令返回以下列:

描述

region_group

账户所在的区域组。注意:仅对于覆盖多个 区域组 的组织,才会显示此列。

snowflake_region

账户所在的 Snowflake 区域。Snowflake 区域是云平台区域内与其他 Snowflake 区域隔离的独特位置。Snowflake 区域可以是多租户或单租户(对于 Virtual Private Snowflake 账户)。

created_on

故障转移组的创建日期和时间。

account_name

账户的名称。

name

故障转移组的名称。

type

组的类型。有效值为 FAILOVER

comment

注释字符串。

is_primary

指示故障转移组是否为主组。

primary

主组的名称。

object_types

为复制和故障转移启用的指定对象类型的列表。

allowed_integration_types

为复制启用的集成类型列表。

即使未在 CREATE FAILOVER GROUP 或 ALTER FAILOVER GROUP 命令中指定集成,Snowflake 也始终在输出中包含此列。

allowed_accounts

为复制和故障转移启用的账户的列表。

organization_name

Snowflake 组织的名称。

account_locator

区域中的账户定位器。

replication_schedule

计划的刷新间隔;如果未设置复制计划,则为 NULL。

secondary_state

计划刷新的当前状态。有效值为 startedsuspended。如果未设置复制计划,则为 NULL。

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.

示例

列出账户 myaccount1 中的故障转移组。

SHOW FAILOVER GROUPS IN ACCOUNT myaccount1;

+------------------+-------------------------------+--------------+------+----------+---------+------------+-----------------------+---------------------------------------------+---------------------------+----------------------------------------------+-------------------+-------------------+----------------------+-----------------+-------------------------------+------------+-----------------------------------+
| snowflake_region | created_on                    | account_name | name | type     | comment | is_primary | primary               | object_types                                | allowed_integration_types |  allowed_accounts                            | organization_name | account_locator   | replication_schedule | secondary_state | next_scheduled_refresh        | owner      | is_listing_auto_fulfillment_group |
+------------------+-------------------------------+--------------+------+----------+---------+------------+-----------------------+---------------------------------------------+---------------------------+----------------------------------------------+-------------------+-------------------+----------------------+-----------------+-------------------------------+------------+-----------------------------------+
| AWS_US_EAST_1    | 2021-10-25 19:08:15.209 -0700 | MYACCOUNT1   | MYFG | FAILOVER |         | true       | MYORG.MYACCOUNT1.MYFG | DATABASES, ROLES, USERS, WAREHOUSES, SHARES |                           | MYORG.MYACCOUNT1.MYFG,MYORG.MYACCOUNT2.MYFG  | MYORG             | MYACCOUNT1LOCATOR | 10 MINUTE            | NULL            |                               | MYROLE     | false                             |
+------------------+-------------------------------+--------------+------+----------+---------+------------+-----------------------+---------------------------------------------+---------------------------+----------------------------------------------+-------------------+-------------------+----------------------+-----------------+-------------------------------+------------+-----------------------------------+
| AWS_US_WEST_2    | 2021-10-25 19:08:15.209 -0700 | MYACCOUNT2   | MYFG | FAILOVER |         | false      | MYORG.MYACCOUNT1.MYFG |                                             |                           |                                              | MYORG             | MYACCOUNT2LOCATOR | 10 MINUTE            | STARTED         | 2022-03-06 12:10:35.280 -0800 | NULL       | false                             |
+------------------+-------------------------------+--------------+------+----------+---------+------------+-----------------------+---------------------------------------------+---------------------------+----------------------------------------------+-------------------+-------------------+----------------------+-----------------+-------------------------------+------------+-----------------------------------+
Copy
语言: 中文