Answers:
在psql中
\dx
有关详细信息,请参见手册:http : //www.postgresql.org/docs/current/static/app-psql.html
用普通的SQL进行选择是pg_extension
:
SELECT *
FROM pg_extension
http://www.postgresql.org/docs/current/static/catalog-pg-extension.html
\dx
是psql命令,该create extension
功能是在9.0 发布时引入的。因此,是的,您还需要升级psql
(必须始终使用psql
与数据库版本匹配的版本)
select * from pg_extension
此SQL查询给出的输出类似于\dx
:
SELECT e.extname AS "Name", e.extversion AS "Version", n.nspname AS "Schema", c.description AS "Description"
FROM pg_catalog.pg_extension e
LEFT JOIN pg_catalog.pg_namespace n ON n.oid = e.extnamespace
LEFT JOIN pg_catalog.pg_description c ON c.objoid = e.oid AND c.classoid = 'pg_catalog.pg_extension'::pg_catalog.regclass
ORDER BY 1;
感谢https://blog.dbi-services.com/listing-the-extensions-available-in-postgresql/