Skip site navigation (1) Skip section navigation (2)

Re: dbsize command

From: salman <salmanb(at)quietcaresystems(dot)com>
To: Brad Nicholson <bnichols(at)ca(dot)afilias(dot)info>
Cc: "Reynolds, Gregory A" <gregory(dot)a(dot)reynolds(at)lmco(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: dbsize command
Date: 2008-06-23 19:40:15
Message-ID: 485FFC1F.3040306@quietcaresystems.com (view raw or flat)
Thread:
Lists: pgsql-general
Brad Nicholson wrote:
> On Mon, 2008-06-23 at 10:50 -0700, Reynolds, Gregory A wrote:
>> In past versions there was a contrib/dbsize command that would tell
>> you how much storage space was being taken by a table. Is that is
>> still a supported feature in 8.3, and if so what is the syntax or
>> where is the documentation on how to use it?
> 
> There are a series of functions in the database core that will tell you
> this now.
> 
> http://www.postgresql.org/docs/8.3/interactive/functions-admin.html
> 

This is what I use: SELECT 
pg_size_pretty(pg_database_size(current_database()));

Found it a while back on pg-general.

-salman

In response to

Responses

pgsql-general by date

Next:From: Daniel FutermanDate: 2008-06-23 19:43:39
Subject: Update Join Query
Previous:From: NikolaDate: 2008-06-23 19:40:04
Subject: Bulk load data from one table to another

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group