Re: psql \dt and table size

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Bernd Helmle <mailings(at)oopsware(dot)de>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: psql \dt and table size
Date: 2011-03-23 20:24:59
Message-ID: AANLkTin6xaym7_S51UvaESjtwMXxbLFTDgwPUpOP9-Xr@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Mar 21, 2011 at 1:44 PM, Bernd Helmle <mailings(at)oopsware(dot)de> wrote:
> It stroke me today again, that \dt+ isn't displaying the acurate table size
> for tables, since it uses pg_relation_size() till now. With having
> pg_table_size() since PostgreSQL 9.0 available, i believe it would be more
> useful to have the total acquired storage displayed, including implicit
> objects (the mentioned case where it was not very useful atm was a table
> with a big TOAST table).

I guess the threshold question for this patch is whether
pg_table_size() is a "more accurate" table size or just a different
one. It could possible be confusing to display one value in that
column when the server is >= 9.0 and the client is >= 9.1, and a
different value when the server is < 9.0 or the client is < 9.1.

On the other hand, it's clear that there are several people in favor
of this change, so maybe we should just go ahead and do it. Not sure.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Greg Stark 2011-03-23 20:30:04 Re: 2nd Level Buffer Cache
Previous Message Robert Haas 2011-03-23 20:20:47 Re: Re: making write location work (was: Efficient transaction-controlled synchronous replication)