From a8c5e87b7407de7901abeaaa535ce096e8916479 Mon Sep 17 00:00:00 2001 From: Steve Singer Date: Mon, 13 Sep 2010 16:38:25 -0400 Subject: [PATCH] Fix for bug154. Call updateRelName from the ddlScript_complete_int function instead of ddlScript_complete because we want this function to be called on both subscribers and the origin. This issue addresses something like renaming a table via EXECUTE SCRIPT where sl_table will continue to have the old name on subscribers. (cherry picked from commit dfd8816556017fb0a3316b799accf617907c9b62) --- src/backend/slony1_funcs.sql | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/backend/slony1_funcs.sql b/src/backend/slony1_funcs.sql index 4953965b..58fb9dba 100644 --- a/src/backend/slony1_funcs.sql +++ b/src/backend/slony1_funcs.sql @@ -3691,7 +3691,6 @@ declare v_query text; v_row record; begin - perform @NAMESPACE@.updateRelname(p_set_id, p_only_on_node); if p_only_on_node = -1 then return @NAMESPACE@.createEvent('_@CLUSTERNAME@', 'DDL_SCRIPT', p_set_id::text, p_script::text, p_only_on_node::text); @@ -3734,7 +3733,7 @@ begin -- Grab the central configuration lock -- ---- lock table @NAMESPACE@.sl_config_lock; - + perform @NAMESPACE@.updateRelname(p_set_id, p_only_on_node); -- ---- -- Check that we either are the set origin or a current -- subscriber of the set. -- 2.39.5