From: | "Ed L(dot)" <pgsql(at)bluepolka(dot)net> |
---|---|
To: | Andreas Pflug <pgadmin(at)pse-consulting(dot)de>, Neil Conway <neilc(at)samurai(dot)com> |
Cc: | pgsql-patches <pgsql-patches(at)postgresql(dot)org> |
Subject: | Re: dbsize patch |
Date: | 2005-01-27 21:12:54 |
Message-ID: | 200501271412.54393.pgsql@bluepolka.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-patches |
On Thursday January 27 2005 6:59, Andreas Pflug wrote:
> Neil Conway wrote:
> > On Tue, 2005-01-25 at 16:49 -0700, Ed L. wrote:
> >>The attached dbsize patch:
> >>
> >> + makes relation_size(relname) include toast tables;
> >> + adds aggregate_relation_size(relname) to count table data and
> >> indices; + adds indices_size(relname) to report the size of indices
> >> for a relation;
>
> Hm, these are all implementable as SQL functions, do we need these hard
> coded too?
>
> e.g.
> create function aggregate_relation_size(oid) returns int8 as $CODE$
> select sum(pg_relation_size(indexrelid)) from pg_index where indrelid=$1;
> $CODE$ language 'SQL'
Well, it seems quite a bit more complicated than that to me, but I'm going
to rework the patch so it drops into 7.3 as well and resubmit shortly.
Ed
From | Date | Subject | |
---|---|---|---|
Next Message | ITAGAKI Takahiro | 2005-01-27 21:28:32 | Re: [HACKERS] WAL: O_DIRECT and multipage-writer |
Previous Message | Mark Wong | 2005-01-27 18:18:44 | Re: [HACKERS] WAL: O_DIRECT and multipage-writer |