

 从补丁 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\$1ALL\$1COLUMNS
<a name="r_SVV_ALL_COLUMNS"></a>

使用 SVV\$1ALL\$1COLUMNS 可以查看来自 Amazon Redshift 表的列的联合，如 SVV\$1REDSHIFT\$1COLUMNS 中所示，以及所有外部表中所有外部列的合并列表。有关 Amazon Redshift 列的信息，请参阅[SVV\$1REDSHIFT\$1COLUMNS](r_SVV_REDSHIFT_COLUMNS.md)。

SVV\$1ALL\$1COLUMNS 对所有用户可见。超级用户可以查看所有行；普通用户只能查看其自己的数据。有关更多信息，请参阅 [系统表和视图中的数据可见性](cm_chap_system-tables.md#c_visibility-of-data)。

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

[\[See the AWS documentation website for more details\]](http://docs.amazonaws.cn/redshift/latest/dg/r_SVV_ALL_COLUMNS.html)

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

下面的示例返回 SVV\$1ALL\$1COLUMNS 的输出。

```
SELECT *
FROM svv_all_columns
WHERE database_name = 'tickit_db'
    AND TABLE_NAME = 'tickit_sales_redshift'
ORDER BY COLUMN_NAME,
    SCHEMA_NAME
LIMIT 5;

 database_name | schema_name |     table_name        | column_name | ordinal_position | column_default | is_nullable | data_type | character_maximum_length | numeric_precision | numeric_scale | remarks
 --------------+-------------+-----------------------+-------------+------------------+----------------+-------------+-----------+--------------------------+-------------------+---------------+---------
   tickit_db   |    public   | tickit_sales_redshift |    buyerid  |        4         |                |      NO     |  integer  |                          |         32        |       0       |
   tickit_db   |    public   | tickit_sales_redshift | commission  |        9         |                |     YES     |  numeric  |                          |          8        |	2       |
   tickit_db   |    public   | tickit_sales_redshift |    dateid   |        7         |                |      NO     |  smallint |                          |         16        |       0       |
   tickit_db   |    public   | tickit_sales_redshift |   eventid   |        5         |                |      NO     |  integer  |                          |         32        |       0       |
   tickit_db   |    public   | tickit_sales_redshift |    listid   |        2         |                |      NO     |  integer  |                          |         32        |       0       |
```