Re: How to watch for schema changes

Поиск
Список
Период
Сортировка
От Adrian Klaver
Тема Re: How to watch for schema changes
Дата
Msg-id 98bd69ac-8c42-e41b-d369-263efe377158@aklaver.com
обсуждение исходный текст
Ответ на Re: How to watch for schema changes  (Igor Korot <ikorot01@gmail.com>)
Список pgsql-general
On 12/3/18 1:53 PM, Igor Korot wrote:
> Hi, Adrian,
> 

>> Why? Just create the trigger once in a script. Event triggers are an
>> attribute of the database and stay with it until they are dropped. If
>> you want to turn then on and off use the ALTER  EVENT TRIGGER
>> ENABLE/DISABLE. If you insist on recreating them on each connection then:
>>
>> https://www.postgresql.org/docs/10/sql-dropeventtrigger.html
>> DROP EVENT TRIGGER [ IF EXISTS ] name [ CASCADE | RESTRICT ]
>> CREATE EVENT TRIGGER ...
> 
> I was hoping to create a software which will be just "install-and-use".
> No additional script running or database changes is required.

Out of curiosity more then anything else:

The database schema this is running against never changes?

The triggers cannot be included in the initial database setup?


> 
> But I will probably create it on every connection and delete on the
> disconnect (see above).
> 


-- 
Adrian Klaver
adrian.klaver@aklaver.com


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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: How to watch for schema changes
Следующее
От: Adrian Klaver
Дата:
Сообщение: Re: How to watch for schema changes