Greetings,
Attached is a rather small change to src/bin/psql/describe.c to
show database size and permissions when using the psql \l command.
Typical output would be:
List of databases
Name | Owner | Encoding | Size | Access privileges
-----------+-------+----------+---------
+-------------------------------------------
andy | andy | UTF8 | 734 MB | {andy=CTc/andy}
postgres | pgsql | UTF8 | 3914 kB |
template0 | pgsql | UTF8 | 3656 kB | {=c/pgsql,pgsql=CTc/pgsql}
template1 | pgsql | UTF8 | 4034 kB | {=c/pgsql,pgsql=CTc/pgsql}
Hope someone finds this useful.
Best regards,
-Andy
Responses
pgsql-hackers by date
| Next: | From: Tom Lane | Date: 2008-01-20 02:06:59 |
| Subject: Re: [PATCH] Add size/acl information when listing databases |
| Previous: | From: Alvaro Herrera | Date: 2008-01-20 01:11:44 |
| Subject: Re: [pgtranslation-translators] message string fixes |