Re: Issues with patitionning and triggers - Mailing list pgsql-general

From Tom Lane
Subject Re: Issues with patitionning and triggers
Date
Msg-id 10600.1392830392@sss.pgh.pa.us
Whole thread Raw
In response to Re: Issues with patitionning and triggers  (Samuel Gilbert <samuel.gilbert@ec.gc.ca>)
List pgsql-general
Samuel Gilbert <samuel.gilbert@ec.gc.ca> writes:
> Here is a complete example demonstrating the issue I am encountering :

What seems to be happening is:

1. The parent table has a NOT NULL constraint on modificationDate.

2. parent_dispatcher_trigger does RETURN NEW, so the tuple will be
inserted into the parent table as well as the selected child (presumably
this is not what you wanted ...)

3. There is no trigger that will replace the modificationDate for an
insertion into the parent.  So the parent insertion fails, after all
the triggers have run.

            regards, tom lane


pgsql-general by date:

Previous
From: salah jubeh
Date:
Subject: Re: Support for Alert
Next
From: Leonardo M. Ramé
Date:
Subject: pg_dump/pg_restore issues