Last Updated: February 25, 2016
·
8.989K
· jasdeepsingh

Postgres Expanded Display

instead of using a crowded single row display like below:

psql_development=# \dx
                           List of installed extensions
  Name   | Version |   Schema   |                   Description                    
---------+---------+------------+--------------------------------------------------
 hstore  | 1.0     | jasdeep    | data type for storing sets of (key, value) pairs
 plpgsql | 1.0     | pg_catalog | PL/pgSQL procedural language
(2 rows)

Use an extended display in psql as follows:

psql_development=# \x
Expanded display is on.

Now all commands executed will return data in an extended table format:

psql_development=# \dx
List of installed extensions
-[ RECORD 1 ]-------------------------------------------------
Name        | hstore
Version     | 1.0
Schema      | jasdeep
Description | data type for storing sets of (key, value) pairs
-[ RECORD 2 ]-------------------------------------------------
Name        | plpgsql
Version     | 1.0
Schema      | pg_catalog
Description | PL/pgSQL procedural language