Christopher B. Browne's Home Page
cbbrowne@acm.org

8.105. setmovesequence_int(integer, integer)

Function Properties

PLPGSQLinteger
setMoveSequence_int(p_seq_id, p_new_set_id) - processes the SET_MOVE_SEQUENCE event, moving a sequence to another replication set.
    declare
    	p_seq_id			alias for $1;
    	p_new_set_id		alias for $2;
    begin
    	-- ----
    	-- Grab the central configuration lock
    	-- ----
    	lock table sl_config_lock;
    	
    	-- ----
    	-- Move the sequence to the new set
    	-- ----
    	update sl_sequence
    			set seq_set = p_new_set_id
    			where seq_id = p_seq_id;
    
    	return p_seq_id;
    end;

Google

If this was useful, let others know by an Affero rating

Contact me at cbbrowne@acm.org