Managing installed extensions
In the last two recipes, we showed you how to install external modules in PostgreSQL to augment its capabilities.
In this recipe, we will show you some more capabilities offered by the extension infrastructure.
How to do it…
- First, we list all the available extensions:
postgres=# \x on Expanded display is on. postgres=# SELECT * postgres-# FROM pg_available_extensions postgres-# ORDER BY name; -[ RECORD 1 ]-----+-------------------------------------------------- name | adminpack default_version | 1.0 installed_version | comment | administrative functions for PostgreSQL -[ RECORD 2 ]-----+-------------------------------------------------- name | pg_stat statements default_version | 1.5 installed_version | comment | track execution statistics of all SQL statements executed (...)
In particular, if the dblink
extension is installed, then we see a record like this:
-[ RECORD 10 ]----+-----------------------------------...