summaryrefslogtreecommitdiff
path: root/src/pl/plpgsql
diff options
context:
space:
mode:
authorPavan Deolasee2015-12-15 08:17:32 +0000
committerPavan Deolasee2016-10-18 09:24:57 +0000
commit8a65b1816f19b9c86b472b128c51a9442b2c5edc (patch)
treea98a186214d6f1eb00ed60c34661944225ed344a /src/pl/plpgsql
parent39d316ba1927f3238bde0ec24778113894ddfec7 (diff)
Add a developer GUC "enable_datanode_row_triggers" to allow ROW TRIGGERS to be
executed on the datanodes. This must be used with caution. Postgres-XL does not officially support triggers yet. One of the reasons for not supporting triggers is that a trigger function executed on a datanode may not have access to all the required data since the data may not reside on the datanode. But if users are confident that the triggers can be safely executed on the datanode, they may turn this GUC on. Still since the feature is not well tested, we don't recommend users to use this without thorough testing and knowing consequences.
Diffstat (limited to 'src/pl/plpgsql')
-rw-r--r--src/pl/plpgsql/src/pl_exec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pl/plpgsql/src/pl_exec.c b/src/pl/plpgsql/src/pl_exec.c
index e803c2fe72..b117816bde 100644
--- a/src/pl/plpgsql/src/pl_exec.c
+++ b/src/pl/plpgsql/src/pl_exec.c
@@ -3478,7 +3478,7 @@ exec_stmt_execsql(PLpgSQL_execstate *estate,
/* PGXCTODO: Support a better parameter interface for XC with DMLs */
if
#ifdef XCP
- (IS_PGXC_DATANODE &&
+ (IS_PGXC_DATANODE && !enable_datanode_row_triggers &&
#endif
(q->commandType == CMD_INSERT ||
q->commandType == CMD_UPDATE ||