Re: Finding the size of your biggest relations

From: hubert depesz lubaczewski <depesz(at)depesz(dot)com>
To: Artem Tomyuk <admin(at)leboutique(dot)com>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: Finding the size of your biggest relations
Date: 2016-09-23 13:21:23
Message-ID: 20160923132122.jcpbobqzf3x4emda@depesz.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On Fri, Sep 23, 2016 at 03:57:52PM +0300, Artem Tomyuk wrote:
> i am running this query to get to 20 biggest tables but getting only
> pg_temp** records like this without size:

What query did you run?

For finding largest tables, I use:

select oid::regclass, pg_table_size(oid) from pg_class where relkind
= 'r' order by 2 desc limit 20;

Best regards,

depesz

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Artem Tomyuk 2016-09-23 13:31:39 Re: Finding the size of your biggest relations
Previous Message Artem Tomyuk 2016-09-23 12:57:52 Finding the size of your biggest relations