postgres base size code example Example: postgres base size SELECT pg_size_pretty( pg_database_size('dbname') );