Re: Date created for tables

Michael Paquier <[email protected]>
Newsgroups gmane.comp.db.postgresql.general
Message-ID <[email protected]>
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
signature.asc (application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE-----

iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAl3psZQACgkQnvQgOdby
QH27WRAAnDJKF8qu2zN3DF0ouZqB+mcarzTT/aM8EG/fteDyZq7s48sJHf62CBtO
fCLVxAY3Kfopd+wWG/SIb29+1sbqvY/JEdw2y9bpcK7Nt+eLY3hhMYrUDRhdbY3c
VSt09TkZoJD0pnRwY2P1ySC+zSuXIQ4W/ZyB/0J/88SZFL5lIprm0R/hpPZBP1I/
u9NmZ98Nf04ECSaeX0tXZefJSP0EuDmlM++s2k8FuQ4WoiQnFLUb1Z8HncVUDxpp
O60t7kby5Lp41PGGaLDKTh0L47ZZhhQQsw5sGKi5BSGPEdEtlLVh4CbhlI8xXt7B
/BxZTlRm4DF7i7plI8/m/Q3kjRhHs/LGMz0CJ3nvFMYJIR3DmoLD0X8NQxUkeb9r
jZK728gFcubmPcb6KP5x0tx0MKEMjAo9I7mgmFbaiaCUhvekk8g2kI79Vcaxv0UY
cqAiKSlVuxjtuR+WykEogZu+ZpIFgk70pMxkgzMhY8iu4g8AVXt0SuhM/gKHZJsC
HW/glEDXkda06fZJT9k1tJGlZEc+b/Dc5vYiVi50w6jQib7I5h39g2Nk9EBKnpVB
OznceVEfTmfQwIuX9JZs67UnBDUSIzvGcRPS+675VCr9YhdDwDEqidg+4x2byklQ
M+bLND5dbPL5wrZBPUuaSScXOchM/zEJzBHQHwGZ+dvIk89WHWo=
=GFr9
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.