Re: Way to quickly detect if database tables/columns/etc. were modified?

Поиск
Список
Период
Сортировка
От Adrian Klaver
Тема Re: Way to quickly detect if database tables/columns/etc. were modified?
Дата
Msg-id cba8a30c-d991-d213-f9d6-6c26a3189039@aklaver.com
обсуждение исходный текст
Ответ на Re: Way to quickly detect if database tables/columns/etc. were modified?  (Melvin Davidson <melvin6925@gmail.com>)
Список pgsql-general
On 10/31/2016 07:17 AM, Melvin Davidson wrote:
>
>
> On Mon, Oct 31, 2016 at 9:48 AM, Karsten Hilbert
> <Karsten.Hilbert@gmx.net <mailto:Karsten.Hilbert@gmx.net>> wrote:
>
>     On Mon, Oct 31, 2016 at 09:14:07AM -0400, Melvin Davidson wrote:
>
>     >> Maybe create an event trigger that updates a simple table with the last
>     >> modification time or sends a notification?
>     ...
>     > That would certainly work, but
>     > the problem is, that trigger would have to be created for every table in
>     > the database. When you have more than a couple dozen tables, as in
>     > hundreds, it becsmes a huge undertaking.*--
>
>     Well, it could be generated.
>
>     Karsten
>     --
>     GPG key ID E4071346 @ eu.pool.sks-keyservers.net
>     <http://eu.pool.sks-keyservers.net>
>     E167 67FD A291 2BEA 73BD  4537 78B9 A9F9 E407 1346
>
>
>     --
>     Sent via pgsql-general mailing list (pgsql-general@postgresql.org
>     <mailto:pgsql-general@postgresql.org>)
>     To make changes to your subscription:
>     http://www.postgresql.org/mailpref/pgsql-general
>     <http://www.postgresql.org/mailpref/pgsql-general>
>
>
>>Well, it could be generated.
> True, but it still is more code to maintain, whereas I maintain the
> addition addition of one column in pg_class and pg_attribute with a
> default of now()
> would make more sense. That being said, there were so many naysayers
> grasping at corner cases the last time I brought this up I have given up
> pursuing it.

For those that want to see the previous discussions and the non-trivial
issues that where raised:

https://www.postgresql.org/message-id/CANu8FizWg8GMSmm_d8X0B6uYi7o535f3vqMD3nqFXqrrYB6huA%40mail.gmail.com

https://www.postgresql.org/message-id/mbrynjrrq6ckoxap20n2gqx4.1461185428476%40email.android.com

>
> --
> *Melvin Davidson*
> I reserve the right to fantasize.  Whether or not you
> wish to share my fantasy is entirely up to you.


--
Adrian Klaver
adrian.klaver@aklaver.com


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

Предыдущее
От: Kim Rose Carlsen
Дата:
Сообщение: Re: How to hint 2 coulms IS NOT DISTINCT FROM each other
Следующее
От: Steve Crawford
Дата:
Сообщение: Re: Way to quickly detect if database tables/columns/etc. were modified?