Re: Proposal: Store "timestamptz" of database creation on "pg_database"
От | Dimitri Fontaine |
---|---|
Тема | Re: Proposal: Store "timestamptz" of database creation on "pg_database" |
Дата | |
Msg-id | m2wqw1ne14.fsf@2ndQuadrant.fr обсуждение исходный текст |
Ответ на | Re: Proposal: Store "timestamptz" of database creation on "pg_database" (Fabrízio de Royes Mello <fabriziomello@gmail.com>) |
Ответы |
Re: Proposal: Store "timestamptz" of database creation on
"pg_database"
|
Список | pgsql-hackers |
Fabrízio de Royes Mello <fabriziomello@gmail.com> writes: > Event triggers don't cover "CREATE DATABASE" statement. The reason why is because you create Event Triggers in a specific database and they only get run when you happen to be connected to that specific database. So for example say you install your Event Trigger in the "postgres" database but then do a CREATE DATABASE while connected to "mydb", the Event Trigger is not installed and will not fire. It's the same analysis about tablespaces and roles, for all global objects in fact. I don't think there's much of a technical implementation reason why not supporting Event Triggers on those, it's all about POLA violation. I personnaly think that given a good documentation coverage having Event Trigger on global objects could be useful enough, even if you would have to install them in every database when you want them to fire no matter what. Regards, -- Dimitri Fontaine http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support
В списке pgsql-hackers по дате отправления: