Re: Creation date of postgres database

Поиск
Список
Период
Сортировка
От Michael Fuhr
Тема Re: Creation date of postgres database
Дата
Msg-id 20060330110626.GA98684@winnie.fuhr.org
обсуждение исходный текст
Ответ на Creation date of postgres database  (Pradeep Sharma <pradeep.sharma@in2m.com>)
Ответы Re: Creation date of postgres database  (Pradeep Sharma <pradeep.sharma@in2m.com>)
Список pgsql-admin
On Thu, Mar 30, 2006 at 02:05:24PM +0530, Pradeep Sharma wrote:
> Is there any way to get the date of creation of a database in Postgres?
> Does postgres store this information in any system table.

I'm not aware that the creation time is stored anywhere (except
perhaps in query logs) but you might be able to infer it from the
modification times of the oldest files in the database's directory.
PG_VERSION looks like a good candidate -- the backend probably
doesn't modify it after the database is created, so if nothing at
the OS level has touched that file then its modification time should
reflect the database's creation time.

--
Michael Fuhr

В списке pgsql-admin по дате отправления:

Предыдущее
От: Pradeep Sharma
Дата:
Сообщение: Creation date of postgres database
Следующее
От: Pradeep Sharma
Дата:
Сообщение: Re: Creation date of postgres database