From ee940cb63ccf5d3d55f7378dc0593bea850d62b3 Mon Sep 17 00:00:00 2001 From: "Karl O. Pinc" Date: Sun, 1 Oct 2023 16:35:46 -0500 Subject: [PATCH] Trigger functions must RETURN --- db/schemas/lookup/triggers/create/comm_ids.m4 | 4 ++++ db/schemas/lookup/triggers/create/departtypes.m4 | 4 ++++ db/schemas/sokwedb/triggers/create/biography.m4 | 4 ++++ db/schemas/sokwedb/triggers/create/comm_membs.m4 | 1 + 4 files changed, 13 insertions(+) diff --git a/db/schemas/lookup/triggers/create/comm_ids.m4 b/db/schemas/lookup/triggers/create/comm_ids.m4 index 09126b8..a18a291 100644 --- a/db/schemas/lookup/triggers/create/comm_ids.m4 +++ b/db/schemas/lookup/triggers/create/comm_ids.m4 @@ -37,6 +37,8 @@ CREATE OR REPLACE FUNCTION comm_ids_func () IF TG_OP = 'UPDATE' THEN restrict_special_row(`COMM_IDS', `CommID', sdb_unknown_comm) END IF; + + RETURN; END; $$; @@ -48,6 +50,8 @@ CREATE OR REPLACE FUNCTION comm_ids_delete_func () AS $$ BEGIN restrict_delete(`COMM_IDS', `CommID', sdb_unknown_comm) + + RETURN; END; $$; diff --git a/db/schemas/lookup/triggers/create/departtypes.m4 b/db/schemas/lookup/triggers/create/departtypes.m4 index 4e3568e..254a9dd 100644 --- a/db/schemas/lookup/triggers/create/departtypes.m4 +++ b/db/schemas/lookup/triggers/create/departtypes.m4 @@ -37,6 +37,8 @@ CREATE OR REPLACE FUNCTION departtypes_func () IF TG_OP = 'UPDATE' THEN restrict_special_row(`DEPARTTYPES', `CommID', sdb_end_of_obs) END IF; + + RETURN; END; $$; @@ -48,6 +50,8 @@ CREATE OR REPLACE FUNCTION departtypes_delete_func () AS $$ BEGIN restrict_delete(`DEPARTTYPES', `CommID', sdb_end_of_obs) + + RETURN; END; $$; diff --git a/db/schemas/sokwedb/triggers/create/biography.m4 b/db/schemas/sokwedb/triggers/create/biography.m4 index a665148..d61477d 100644 --- a/db/schemas/sokwedb/triggers/create/biography.m4 +++ b/db/schemas/sokwedb/triggers/create/biography.m4 @@ -359,6 +359,8 @@ CREATE OR REPLACE FUNCTION biography_func () || ')'; END IF; END; + + RETURN; END; $$; @@ -381,6 +383,8 @@ CREATE OR REPLACE FUNCTION biography_delete_func () -- All but the youngest sibling (or siblings in the case of twins) -- must have FirstBorn of sdb_not_firstborn. check_firstborn(`OLD', `Deleting the BIOGRAPHY row') + + RETURN; END; $$; diff --git a/db/schemas/sokwedb/triggers/create/comm_membs.m4 b/db/schemas/sokwedb/triggers/create/comm_membs.m4 index 034a818..f78cdb3 100644 --- a/db/schemas/sokwedb/triggers/create/comm_membs.m4 +++ b/db/schemas/sokwedb/triggers/create/comm_membs.m4 @@ -174,6 +174,7 @@ CREATE OR REPLACE FUNCTION comm_membs_func () END IF; END; + RETURN; END; $$; -- 2.34.1