pg_available_extensions
是一个 系统目录 视图,列出所有可用的 扩展。
pg_available_extensions
在 PostgreSQL 9.1 中引入。
按PostgreSQL版本定义
pg_available_extensions (PostgreSQL 17)
View "pg_catalog.pg_available_extensions" Column | Type | Collation | Nullable | Default -------------------+------+-----------+----------+--------- name | name | | | default_version | text | | | installed_version | text | C | | comment | text | | |
pg_available_extensions (PostgreSQL 16)
View "pg_catalog.pg_available_extensions" Column | Type | Collation | Nullable | Default -------------------+------+-----------+----------+--------- name | name | | | default_version | text | | | installed_version | text | C | | comment | text | | |
pg_available_extensions (PostgreSQL 15)
View "pg_catalog.pg_available_extensions" Column | Type | Collation | Nullable | Default -------------------+------+-----------+----------+--------- name | name | | | default_version | text | | | installed_version | text | C | | comment | text | | |
pg_available_extensions (PostgreSQL 14)
View "pg_catalog.pg_available_extensions" Column | Type | Collation | Nullable | Default -------------------+------+-----------+----------+--------- name | name | | | default_version | text | | | installed_version | text | C | | comment | text | | |
pg_available_extensions (PostgreSQL 13)
View "pg_catalog.pg_available_extensions" Column | Type | Collation | Nullable | Default -------------------+------+-----------+----------+--------- name | name | | | default_version | text | | | installed_version | text | C | | comment | text | | |
pg_available_extensions (PostgreSQL 12)
View "pg_catalog.pg_available_extensions" Column | Type | Collation | Nullable | Default -------------------+------+-----------+----------+--------- name | name | | | default_version | text | | | installed_version | text | C | | comment | text | | |
pg_available_extensions (PostgreSQL 11)
View "pg_catalog.pg_available_extensions" Column | Type | Collation | Nullable | Default -------------------+------+-----------+----------+--------- name | name | | | default_version | text | | | installed_version | text | | | comment | text | | |
pg_available_extensions (PostgreSQL 10)
View "pg_catalog.pg_available_extensions" Column | Type | Collation | Nullable | Default -------------------+------+-----------+----------+--------- name | name | | | default_version | text | | | installed_version | text | | | comment | text | | |
pg_available_extensions (PostgreSQL 9.6)
View "pg_catalog.pg_available_extensions" Column | Type | Modifiers -------------------+------+----------- name | name | default_version | text | installed_version | text | comment | text |
pg_available_extensions (PostgreSQL 9.5)
View "pg_catalog.pg_available_extensions" Column | Type | Modifiers -------------------+------+----------- name | name | default_version | text | installed_version | text | comment | text |
pg_available_extensions (PostgreSQL 9.4)
View "pg_catalog.pg_available_extensions" Column | Type | Modifiers -------------------+------+----------- name | name | default_version | text | installed_version | text | comment | text |
pg_available_extensions (PostgreSQL 9.3)
View "pg_catalog.pg_available_extensions" Column | Type | Modifiers -------------------+------+----------- name | name | default_version | text | installed_version | text | comment | text |
pg_available_extensions (PostgreSQL 9.2)
View "pg_catalog.pg_available_extensions" Column | Type | Modifiers -------------------+------+----------- name | name | default_version | text | installed_version | text | comment | text |
pg_available_extensions (PostgreSQL 9.1)
View "pg_catalog.pg_available_extensions" Column | Type | Modifiers -------------------+------+----------- name | name | default_version | text | installed_version | text | comment | text |
更改历史记录
- PostgreSQL 9.1
- 添加 (提交 d9572c4e)
示例
postgres=# SELECT * FROM pg_available_extensions WHERE name LIKE 'p%'; name | default_version | installed_version | comment --------------------+-----------------+-------------------+------------------------------------------------------------------- pg_trgm | 1.4 | | text similarity measurement and index searching based on trigrams plpgsql | 1.0 | 1.0 | PL/pgSQL procedural language plperl | 1.0 | | PL/Perl procedural language pg_prewarm | 1.2 | | prewarm relation data pg_freespacemap | 1.2 | | examine the free space map (FSM) pgstattuple | 1.5 | 1.5 | show tuple-level statistics postgres_fdw | 1.0 | | foreign-data wrapper for remote PostgreSQL servers pgrowlocks | 1.2 | | show row-level locking information pg_stat_statements | 1.6 | 1.6 | track execution statistics of all SQL statements executed pgcrypto | 1.3 | | cryptographic functions pg_buffercache | 1.3 | | examine the shared buffer cache plperlu | 1.0 | | PL/PerlU untrusted procedural language pageinspect | 1.7 | | inspect the contents of database pages at a low level pg_visibility | 1.2 | | examine the visibility map (VM) and page-level visibility info (14 rows)
参考文献
- PostgreSQL文档: pg_available_extensions