From: | Shreeyansh Dba <shreeyansh2014(at)gmail(dot)com> |
---|---|
To: | Frantz Song <frantz(dot)song(at)gmail(dot)com> |
Cc: | pgsql-admin(at)lists(dot)postgresql(dot)org |
Subject: | Re: How to find the table which is not used in recent 3 month? |
Date: | 2018-12-31 11:24:23 |
Message-ID: | CAGDYbUPmY9Wqx90Yj0gu1Bm588dTesPpfpvCBWbEuEixtEOpTg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
Hi Frantz,
You can trace the timestamp by using below query, it shows the list of the
table which is not modified or unused since last 3 month.
select relname, NOW()-interval '3 month' from pg_stat_user_tables where
n_live_tup=0;
Thanks & Regards,
*Shreeyansh DBA Team*
www.shreeyansh.com
On Mon, Dec 31, 2018 at 11:59 AM Frantz Song <frantz(dot)song(at)gmail(dot)com> wrote:
> Dear all,
>
> I'm use postgresql 9.6, it have 800+tables and some of them is not
> frequently used.
> How to find the table which is not used in recent 3 month?
>
> Thanks!
>
> --
> P Help save trees...please don't print this e-mail* unless you really
> need to.*
>
From | Date | Subject | |
---|---|---|---|
Next Message | Fabio Pardi | 2018-12-31 13:22:07 | Re: How to find the table which is not used in recent 3 month? |
Previous Message | Sylvain Fauvel | 2018-12-31 08:49:07 | Re: How to find the table which is not used in recent 3 month? |