Difference between revisions of "PostgreSQL: \list"

From wikieduonline
Jump to navigation Jump to search
Line 31: Line 31:
 
   rdsadmin          | rdsadmin            | UTF8    | en_US.UTF-8 | en_US.UTF-8 | rdsadmin=CTc/rdsadmin                      +
 
   rdsadmin          | rdsadmin            | UTF8    | en_US.UTF-8 | en_US.UTF-8 | rdsadmin=CTc/rdsadmin                      +
 
                     |                    |          |            |            | rdstopmgr=Tc/rdsadmin
 
                     |                    |          |            |            | rdstopmgr=Tc/rdsadmin
   template0          | rdsadmin            | UTF8    | en_US.UTF-8 | en_US.UTF-8 | =c/rdsadmin                                +
+
   [[template0]]         | rdsadmin            | UTF8    | en_US.UTF-8 | en_US.UTF-8 | =c/rdsadmin                                +
 
                     |                    |          |            |            | rdsadmin=CTc/rdsadmin
 
                     |                    |          |            |            | rdsadmin=CTc/rdsadmin
   template1          | complete_postgresql | UTF8    | en_US.UTF-8 | en_US.UTF-8 | =c/complete_postgresql                    +
+
   [[template1]]         | complete_postgresql | UTF8    | en_US.UTF-8 | en_US.UTF-8 | =c/complete_postgresql                    +
 
                     |                    |          |            |            | complete_postgresql=CTc/complete_postgresql
 
                     |                    |          |            |            | complete_postgresql=CTc/complete_postgresql
 
  (5 rows)
 
  (5 rows)

Revision as of 22:17, 6 June 2022

List all databases

Examples:

  • \l
  • \list
  • -l
  • --list


postgres-> \list
                                       List of databases
   Name    |   Owner    | Encoding |   Collate   |    Ctype    |       Access privileges
-----------+------------+----------+-------------+-------------+-------------------------------
 YOUR_DB | rds_master | UTF8     | en_US.UTF-8 | en_US.UTF-8 | =Tc/rds_master               +
           |            |          |             |             | rds_master=CTc/rds_master   
 rdsadmin  | rdsadmin   | UTF8     | en_US.UTF-8 | en_US.UTF-8 | rdsadmin=CTc/rdsadmin
 template0 | rdsadmin   | UTF8     | en_US.UTF-8 | en_US.UTF-8 | =c/rdsadmin                  +
           |            |          |             |             | rdsadmin=CTc/rdsadmin
 template1 | rds_master | UTF8     | en_US.UTF-8 | en_US.UTF-8 | rds_master=CTc/rds_master    +
           |            |          |             |             | =c/rds_master
(4 rows)
completePostgresql=>  \list
                                                       List of databases
        Name        |        Owner        | Encoding |   Collate   |    Ctype    |              Access privileges
--------------------+---------------------+----------+-------------+-------------+---------------------------------------------
 completePostgresql | complete_postgresql | UTF8     | en_US.UTF-8 | en_US.UTF-8 |
 postgres           | complete_postgresql | UTF8     | en_US.UTF-8 | en_US.UTF-8 |
 rdsadmin           | rdsadmin            | UTF8     | en_US.UTF-8 | en_US.UTF-8 | rdsadmin=CTc/rdsadmin                      +
                    |                     |          |             |             | rdstopmgr=Tc/rdsadmin
 template0          | rdsadmin            | UTF8     | en_US.UTF-8 | en_US.UTF-8 | =c/rdsadmin                                +
                    |                     |          |             |             | rdsadmin=CTc/rdsadmin
 template1          | complete_postgresql | UTF8     | en_US.UTF-8 | en_US.UTF-8 | =c/complete_postgresql                     +
                    |                     |          |             |             | complete_postgresql=CTc/complete_postgresql
(5 rows)


Related terms

See also

Advertising: