From: | Miroslav Šimulčík <simulcik(dot)miro(at)gmail(dot)com> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Storing original rows before update or delete |
Date: | 2011-11-04 09:20:06 |
Message-ID: | CAHRNM6_06yVtvQGDXjH3RnO638zABenaiiptFk22S_DgYb244Q@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi.
I'm working on transactiontime temporal support for postgresql 9.0.4. Each
original table with transactiontime support has associated history table,
where original row is stored before each update or delete operation on it.
Both original and history tables have internal timestamp columns for
storing the period of validity of row versions. History tables are internal
and I want to restrict any DML operation on it, so nobody can change
history of operations made on original table. Problem is, that I don't know
where to implement the mechanism for storing original rows to history
tables. Rewrite rules are not suitable, because they are not working with
inheritance and I can't use triggers, because inserts to history tables are
restricted. Can you point me to place in postgresql backend where can i
implement this and maybe give me some hints about how to do it correctly?
Thank you.
Best regards
Miroslav Simulcik
From | Date | Subject | |
---|---|---|---|
Next Message | Szymon Guz | 2011-11-04 09:29:10 | Re: Storing original rows before update or delete |
Previous Message | Simon Riggs | 2011-11-04 09:15:42 | Re: DeArchiver process |