Re: Proposal: Store "timestamptz" of database creation on "pg_database"

From: Bernd Helmle <mailings(at)oopsware(dot)de>
To: Robert Haas <robertmhaas(at)gmail(dot)com>, Stephen Frost <sfrost(at)snowman(dot)net>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Josh Berkus <josh(at)agliodbs(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Proposal: Store "timestamptz" of database creation on "pg_database"
Date: 2013-01-03 10:28:15
Message-ID: 1E84B2A2B5845C21E27F0C84@apophis.credativ.lan
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

--On 2. Januar 2013 23:04:43 -0500 Robert Haas <robertmhaas(at)gmail(dot)com>
wrote:

> TBH, I don't think anyone has any business changing the creation
> timestamp. Ever. For me, the fact that pg_dump wouldn't preserve
> this information would be a feature, not a bug. I mostly meant to
> point out that someone could bypass it if they cared enough, not to
> recommend it. Honestly, I'd probably *rather* store this information
> someplace where it couldn't be changed via SQL *at all*. But I don't
> think we have such a place, so I'm happy enough to store it in the
> catalogs, with the associated risks of catalog hackery that entails.

This is exactly what Informix does, it stores creation or modification
dates of a table in its system catalog (systables.created, to be specific).
Any export/import of tables doesn't preserve the dates, if you restore a
database (or table), the creation date is adjusted. I'm not aware of any
SQL interface to influence this.

--
Thanks

Bernd

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Hannu Krosing 2013-01-03 10:54:03 Re: Proposal: Store "timestamptz" of database creation on "pg_database"
Previous Message Pavel Stehule 2013-01-03 10:20:09 Re: Proposal: Store "timestamptz" of database creation on "pg_database"