Re: Keeping creation time of objects - Mailing list pgsql-hackers

From daveg
Subject Re: Keeping creation time of objects
Date
Msg-id 20080909194059.GJ21082@sonic.net
Whole thread Raw
In response to Re: Keeping creation time of objects  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Keeping creation time of objects  (Hannu Krosing <hannu@2ndQuadrant.com>)
List pgsql-hackers
On Tue, Sep 09, 2008 at 03:36:19PM -0400, Tom Lane wrote:
> Devrim GÜNDÜZ <devrim@gunduz.org> writes:
> > AFAICS, PostgreSQL is not keeping info about when a table, database,
> > sequence, etc was created. We cannot get that info even from OS, since
> > CLUSTER or VACUUM FULL may change the metadata of corresponding
> > relfilenode.
> 
> > Does anyone think that adding a timestamp column to pg_class would bring
> > an overhead?
> 
> There isn't sufficient support for such a "feature".  In any case, why
> would creation time (as opposed to any other time, eg last schema
> modification, last data modification, yadda yadda) be especially
> significant?  Would you expect it to be preserved over dump/restore?
> How about every other object type in the system?

I'd be very interested in seeing a last schema modification time for pg_class
objects. I don't care about it being preserved over dump and restore as my
use case is more to find out when a table was created with a view to finding
out if it is still needed. So the question I'm looking to answer is "when did
that get here?"

-dg

-- 
David Gould       daveg@sonic.net      510 536 1443    510 282 0869
If simplicity worked, the world would be overrun with insects.


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Keeping creation time of objects
Next
From: Devrim GÜNDÜZ
Date:
Subject: Re: Keeping creation time of objects