Re: Trigger to create automated range partition table
| От | legrand legrand |
|---|---|
| Тема | Re: Trigger to create automated range partition table |
| Дата | |
| Msg-id | 1542787797239-0.post@n3.nabble.com обсуждение исходный текст |
| Ответ на | Re: Trigger to create automated range partition table (Keith <keith@keithf4.com>) |
| Список | pgsql-admin |
I confirm: This is not working now for pg10 see https://www.postgresql-archive.org/BUG-15437-Segfault-during-insert-into-declarative-partitioned-table-with-a-trigger-creating-partition-td6054925.html this kind of trigger is even not supported in pg11 postgres=# CREATE TRIGGER check_pkey BEFORE INSERT ON tabpart postgres-# FOR EACH ROW EXECUTE PROCEDURE public.f_check_pkey(); ERROR: "tabpart" is a partitioned table DETAIL: Partitioned tables cannot have BEFORE / FOR EACH ROW triggers. There are many development works regarding this see all threads about ATTACH/DETACH PARTITION CONCURRENTLY for example Today the only solution is to create those partitions before the first INSERT statement ;o( Regards PAscal -- Sent from: http://www.postgresql-archive.org/PostgreSQL-admin-f2076596.html
В списке pgsql-admin по дате отправления: