- -- Update the snapshot ready for the next run.
- TRUNCATE public.pg_settings_last;
- INSERT INTO pg_settings_last (name, setting, unit, category, short_desc, extra_desc, context, vartype, source, min_val,
+ IF (v_changes > 0) THEN
+ -- Update the snapshot ready for the next run.
+ TRUNCATE public.pg_settings_last;
+ INSERT INTO pg_settings_last (name, setting, unit, category, short_desc, extra_desc, context, vartype, source, min_val,