

 从补丁 198 开始，Amazon Redshift 将不再支持创建新的 Python UDF。现有的 Python UDF 将继续正常运行至 2026 年 6 月 30 日。有关更多信息，请参阅[博客文章](https://www.amazonaws.cn/blogs/big-data/amazon-redshift-python-user-defined-functions-will-reach-end-of-support-after-june-30-2026/)。

# SVV\_INTEGRATION\_TABLE\_STATE
<a name="r_SVV_INTEGRATION_TABLE_STATE"></a>

SVV\_INTEGRATION\_TABLE\_STATE 显示有关表级集成信息的详情。

SVV\_INTEGRATION\_TABLE\_STATE 仅对超级用户可见。有关更多信息，请参阅 [系统表和视图中的数据可见性](cm_chap_system-tables.md#c_visibility-of-data)。

有关更多信息，请参阅 [Zero-ETL integrations](https://docs.amazonaws.cn/redshift/latest/mgmt/zero-etl-using.html)。

## 表列
<a name="r_SVV_INTEGRATION_TABLE_STATE-table-columns"></a>


| 列名称  | 数据类型  | 说明  | 
| --- | --- | --- | 
| integration\_id | character(128) | 与集成关联的标识符。 | 
| target\_database | character(128) | Amazon Redshift 数据库的名称。 | 
| schema\_name | character(128) | Amazon Redshift 架构的名称。 | 
| table\_name | character(128) | 表的名称。 | 
| table\_state | character(128) | 表的状态。可能的值为 Synced、Failed、Deleted、ResyncRequired、ResyncInitiated 和 DroppedSource。DroppedSource 状态表示已从来源中删除历史记录模式表的源。 | 
| table\_last\_replicated\_checkpoint | character(128) | 当前同步的日志坐标。 | 
| reason | character(256) | 最后一次状态转换的原因。常见原因可能是表中存在不支持的数据类型，表没有主键。要了解有关如何排查常见问题的更多信息，请参阅 [Troubleshooting zero-ETL integrations in Amazon Redshift](https://docs.amazonaws.cn/redshift/latest/mgmt/zero-etl-using.troubleshooting.html)。 | 
| last\_updated\_timestamp | 不带时区的时间戳 | 表最后一次更新的时间 (UTC)。 | 
| table\_rows | bigint | 表中的总行数。 | 
| table\_size | bigint | 表的大小，以兆字节（MB）为单位。 | 
| is\_history\_mode | 布尔值 | TRUE 值表示历史记录模式已启用。FALSE 表示历史记录模式已禁用。 | 

## 示例查询
<a name="r_SVV_INTEGRATION_TABLE_STATE-sample-queries"></a>

以下 SQL 命令显示集成日志的列。

```
select * from svv_integration_table_state;

          integration_id              | target_database | schema_name |     table_name    | table_state  |table_last_replicated_checkpoint | reason | last_updated_timestamp     |table_rows  | table_size | is_history_mode 
--------------------------------------+-----------------+-------------+-------------------+--------------+---------------------------------+--------+----------------------------+------------+------------+-----------------
 4798e675-8f9f-4686-b05f-92c538e19629 |  sample_test2   |    sample   | SampleTestChannel |    Synced    |   {"txn_seq":3,"txn_id":3122}   |        | 2023-05-12 12:40:30.656625 | 2          |   16       | f
```