x
1
-- File: trig_i_i_syst_hierarchies.eex.sql
2
-- Location: musebms/database/components/system/mscmp_syst_hierarchy/ms_syst/api_views/syst_hierarchies/trig_i_i_syst_hierarchies.eex.sql
3
-- Project: Muse Systems Business Management System
4
--
5
-- Copyright © Lima Buttgereit Holdings LLC d/b/a Muse Systems
6
-- This file may include content copyrighted and licensed from third parties.
7
--
8
-- See the LICENSE file in the project root for license terms and conditions.
9
-- See the NOTICE file in the project root for copyright ownership information.
10
--
11
-- muse.information@musesystems.com :: https://muse.systems
12
13
BEGIN
14
15
INSERT INTO ms_syst_data.syst_hierarchies
16
( internal_name
17
, display_name
18
, hierarchy_type_id
19
, hierarchy_state_id
20
, syst_defined
21
, user_maintainable
22
, structured
23
, syst_description
24
, user_description )
25
VALUES
26
( new.internal_name
27
, new.display_name
28
, new.hierarchy_type_id
29
, new.hierachy_state_id
30
, FALSE
31
, TRUE
32
, coalesce(new.structured, TRUE)
33
, '(System Description Not Available)'
34
, new.user_description )
35
RETURNING * INTO new;
36
37
RETURN new;
38
39
END;