Slony-I 2.2.11 Documentation
Prev | Fast Backward | Chapter 8. Schema schemadoc | Fast Forward | Next

# 8.129. tablestovacuum()

Function Properties

Language: PLPGSQL

Return Type: SET OF vactables

Return a list of tables that require frequent vacuuming. The function is used so that the list is not hardcoded into C code.

    declare
    	prec vactables%rowtype;
    begin
    	prec.nspname := '_schemadoc';
    	prec.relname := 'sl_event';
    	if ShouldSlonyVacuumTable(prec.nspname, prec.relname) then
    		return next prec;
    	end if;
    	prec.nspname := '_schemadoc';
    	prec.relname := 'sl_confirm';
    	if ShouldSlonyVacuumTable(prec.nspname, prec.relname) then
    		return next prec;
    	end if;
    	prec.nspname := '_schemadoc';
    	prec.relname := 'sl_setsync';
    	if ShouldSlonyVacuumTable(prec.nspname, prec.relname) then
    		return next prec;
    	end if;
    	prec.nspname := '_schemadoc';
    	prec.relname := 'sl_seqlog';
    	if ShouldSlonyVacuumTable(prec.nspname, prec.relname) then
    		return next prec;
    	end if;
    	prec.nspname := '_schemadoc';
    	prec.relname := 'sl_archive_counter';
    	if ShouldSlonyVacuumTable(prec.nspname, prec.relname) then
    		return next prec;
    	end if;
    	prec.nspname := '_schemadoc';
    	prec.relname := 'sl_components';
    	if ShouldSlonyVacuumTable(prec.nspname, prec.relname) then
    		return next prec;
    	end if;
    	prec.nspname := '_schemadoc';
    	prec.relname := 'sl_log_script';
    	if ShouldSlonyVacuumTable(prec.nspname, prec.relname) then
    		return next prec;
    	end if;
    	prec.nspname := 'pg_catalog';
    	prec.relname := 'pg_listener';
    	if ShouldSlonyVacuumTable(prec.nspname, prec.relname) then
    		return next prec;
    	end if;
    	prec.nspname := 'pg_catalog';
    	prec.relname := 'pg_statistic';
    	if ShouldSlonyVacuumTable(prec.nspname, prec.relname) then
    		return next prec;
    	end if;

       return;
    end

Prev | Home | Next
subscribeset_int(p_omit_copy integer, p_sub_forward integer, p_sub_receiver integer, p_sub_provider boolean, p_sub_set boolean) | Up | terminatenodeconnections(p_failed_node integer)