Re: Support TRUNCATE triggers on foreign tables

Поиск
Список
Период
Сортировка
От Fujii Masao
Тема Re: Support TRUNCATE triggers on foreign tables
Дата
Msg-id b2f6d778-7aff-5e0b-4e09-d0b76fa25e9c@oss.nttdata.com
обсуждение исходный текст
Ответ на Support TRUNCATE triggers on foreign tables  (Yugo NAGATA <nagata@sraoss.co.jp>)
Ответы Re: Support TRUNCATE triggers on foreign tables  (Yugo NAGATA <nagata@sraoss.co.jp>)
Список pgsql-hackers

On 2022/06/30 19:38, Yugo NAGATA wrote:
> Hello,
> 
> I propose supporting TRUNCATE triggers on foreign tables
> because some FDW now supports TRUNCATE. I think such triggers
> are useful for audit logging or for preventing undesired
> truncate.
> 
> Patch attached.

Thanks for the patch! It looks good to me except the following thing.

        <entry align="center"><command>TRUNCATE</command></entry>
        <entry align="center">—</entry>
-      <entry align="center">Tables</entry>
+      <entry align="center">Tables and foreign tables</entry>
       </row>

You added "foreign tables" for BEFORE statement-level trigger as the above, but ISTM that you also needs to do that for
AFTERstatement-level trigger. No?
 

Regards,

-- 
Fujii Masao
Advanced Computing Technology Center
Research and Development Headquarters
NTT DATA CORPORATION



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: archive modules
Следующее
От: Fujii Masao
Дата:
Сообщение: Re: Add a test for "cannot truncate foreign table"