Re: Date created for tables - Mailing list pgsql-general

From Michael Paquier
Subject Re: Date created for tables
Date
Msg-id 20191206014036.GF121835@paquier.xyz
Whole thread Raw
In response to Re: Date created for tables  (Ron <ronljohnsonjr@gmail.com>)
Responses Re: Date created for tables
List pgsql-general
On Thu, Dec 05, 2019 at 07:12:22PM -0600, Ron wrote:
> On 12/5/19 1:01 PM, Tom Lane wrote:
>> It's been considered, and rejected, many times.  Aside from the overhead
>> involved, there are too many different ideas of what such dates ought to
>> mean (e.g., what should happen during dump/restore? does a failed
>> transaction update last-modified? etc etc).  You can search the
>> project's mailing list archives if you want to read the prior discussions.
>
> All the other RDBMSs seem to have figured it out.

It does not necessarily mean that Postgres has to do it.  FWIW, you
can track that using an even trigger for CREATE TABLE or other objects
which inserts the following in a table of your choice for a given
database:
- The timestamp of the transaction.
- The object name.
- Its class ID, say pg_class::regclass for a table, etc.
--
Michael

Attachment

pgsql-general by date:

Previous
From: Ron
Date:
Subject: Re: Date created for tables
Next
From: Michael Paquier
Date:
Subject: Re: archiving question