Finding out db size...

Поиск
Список
Период
Сортировка
Искать

Finding out db size...

От:
Christopher.Becker@apcc.com
Дата:




Is there any possible way to do a SQL query to return some sort of
representation of how large the entire db is? Or even how large a single
table is?

Re: Finding out db size...

От:
Bruce Momjian <pgman@candle.pha.pa.us>
Дата:

See the administration chapter of the docs on analyzing disk space.

Christopher.Becker@apcc.com wrote:
> 
> 
> 
> 
> Is there any possible way to do a SQL query to return some sort of
> representation of how large the entire db is? Or even how large a single
> table is?
> 
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
> 

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

Re: Finding out db size...

От:
Devrim GUNDUZ <devrim@gunduz.org>
Дата:

Hi,

On Fri, 30 Apr 2004 Christopher.Becker@apcc.com wrote:

> Is there any possible way to do a SQL query to return some sort of
> representation of how large the entire db is? Or even how large a single
> table is?

See contrib/dbsize

Regards,
--
Devrim GUNDUZ	       
devrim~gunduz.org				devrim.gunduz~linux.org.tr 
			http://www.TDMSoft.com
			http://www.gunduz.org

Re: Finding out db size...

От:
Adam Witney <awitney@sghms.ac.uk>
Дата:

If you install the dbsize extension in the contrib directory for the source
code, then you can run queries like this

SELECT database_size('my_database');
SELECT relation_size('my_table');

HTH

adam


> 
> Is there any possible way to do a SQL query to return some sort of
> representation of how large the entire db is? Or even how large a single
> table is?
> 
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster


-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

FAQ