aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/transam/xact.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/access/transam/xact.c')
-rw-r--r--src/backend/access/transam/xact.c24
1 files changed, 23 insertions, 1 deletions
diff --git a/src/backend/access/transam/xact.c b/src/backend/access/transam/xact.c
index dc5bbcd32eb..f468e2916b1 100644
--- a/src/backend/access/transam/xact.c
+++ b/src/backend/access/transam/xact.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/transam/xact.c,v 1.54 1999/09/28 11:41:03 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/transam/xact.c,v 1.55 1999/09/29 16:05:55 wieck Exp $
*
* NOTES
* Transaction aborts can now occur two ways:
@@ -149,6 +149,7 @@
#include "commands/async.h"
#include "commands/sequence.h"
#include "commands/vacuum.h"
+#include "commands/trigger.h"
#include "libpq/be-fsstubs.h"
#include "storage/proc.h"
#include "storage/sinval.h"
@@ -866,6 +867,12 @@ StartTransaction()
InitNoNameRelList();
/* ----------------
+ * Tell the trigger manager to we're starting a transaction
+ * ----------------
+ */
+ DeferredTriggerBeginXact();
+
+ /* ----------------
* done with start processing, set current transaction
* state to "in progress"
* ----------------
@@ -905,6 +912,14 @@ CommitTransaction()
elog(NOTICE, "CommitTransaction and not in in-progress state ");
/* ----------------
+ * Tell the trigger manager that this transaction is about to be
+ * committed. He'll invoke all trigger deferred until XACT before
+ * we really start on committing the transaction.
+ * ----------------
+ */
+ DeferredTriggerEndXact();
+
+ /* ----------------
* set the current transaction state information
* appropriately during the abort processing
* ----------------
@@ -993,6 +1008,13 @@ AbortTransaction()
elog(NOTICE, "AbortTransaction and not in in-progress state ");
/* ----------------
+ * Tell the trigger manager that this transaction is about to be
+ * aborted.
+ * ----------------
+ */
+ DeferredTriggerAbortXact();
+
+ /* ----------------
* set the current transaction state information
* appropriately during the abort processing
* ----------------