5 INSERT INTO config.org_unit_setting_type (name, label) VALUES ('foo', 'Turn on foo');
6 INSERT INTO config.org_unit_setting_type (name, label) VALUES ('bar', 'Turn on bar');
8 INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES (1, 'foo', '"foo 1"');
9 INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES (2, 'foo', '"foo 2"');
10 INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES (2, 'bar', '"bar 2"');
13 $$ SELECT name, value FROM actor.org_unit_ancestor_setting_batch(1, 'foo', 'bar') $$,
14 $$ VALUES ('foo', '"foo 1"') $$,
15 'can retrieve batch of org unit settings'
19 $$ SELECT name, value FROM actor.org_unit_ancestor_setting_batch(2, 'foo', 'bar') $$,
20 $$ VALUES ('foo', '"foo 2"'), ('bar', '"bar 2"') $$,
21 'can retrieve batch of org unit settings at lower level'
24 DELETE FROM actor.org_unit_setting WHERE name = 'foo' AND org_unit = 2;
26 $$ SELECT name, value FROM actor.org_unit_ancestor_setting_batch(2, 'foo', 'bar') $$,
27 $$ VALUES ('foo', '"foo 1"'), ('bar', '"bar 2"') $$,
28 'can retrieve batch of org unit settings with fallback'