106 lines
3.8 KiB
Plaintext
106 lines
3.8 KiB
Plaintext
CREATE OR REPLACE PACKAGE cg$NETWORK_POINT_MAPPINGS IS
|
|
|
|
|
|
called_from_package BOOLEAN := FALSE;
|
|
|
|
-- Repository User-Defined Error Messages
|
|
NEPM_PK CONSTANT VARCHAR2(240) := '';
|
|
NEPM_NEPO_FK CONSTANT VARCHAR2(240) := '';
|
|
NEPM_NEPG_FK CONSTANT VARCHAR2(240) := '';
|
|
|
|
-- Column default prompts. Format PSEQNO_COL
|
|
P40CREATED_BY CONSTANT VARCHAR2(240) := 'Created By';
|
|
P20NEPG_ID CONSTANT VARCHAR2(240) := 'Nepg Id';
|
|
P30NEPO_ID CONSTANT VARCHAR2(240) := 'Nepo Id';
|
|
P50CREATED_ON CONSTANT VARCHAR2(240) := 'Created On';
|
|
|
|
cg$row NETWORK_POINT_MAPPINGS%ROWTYPE;
|
|
|
|
-- NETWORK_POINT_MAPPINGS row type variable
|
|
TYPE cg$row_type IS RECORD
|
|
(CREATED_BY cg$row.CREATED_BY%TYPE
|
|
,NEPG_ID cg$row.NEPG_ID%TYPE
|
|
,NEPO_ID cg$row.NEPO_ID%TYPE
|
|
,CREATED_ON cg$row.CREATED_ON%TYPE
|
|
,the_rowid ROWID)
|
|
;
|
|
|
|
-- NETWORK_POINT_MAPPINGS indicator type variable
|
|
TYPE cg$ind_type IS RECORD
|
|
(CREATED_BY BOOLEAN DEFAULT FALSE
|
|
,NEPG_ID BOOLEAN DEFAULT FALSE
|
|
,NEPO_ID BOOLEAN DEFAULT FALSE
|
|
,CREATED_ON BOOLEAN DEFAULT FALSE);
|
|
|
|
cg$ind_true cg$ind_type;
|
|
|
|
-- NETWORK_POINT_MAPPINGS primary key type variable
|
|
TYPE cg$pk_type IS RECORD
|
|
(NEPG_ID cg$row.NEPG_ID%TYPE
|
|
,NEPO_ID cg$row.NEPO_ID%TYPE
|
|
,the_rowid ROWID)
|
|
;
|
|
|
|
-- PL/SQL Table Type variable for triggers
|
|
TYPE cg$table_type IS TABLE OF NETWORK_POINT_MAPPINGS%ROWTYPE
|
|
INDEX BY BINARY_INTEGER;
|
|
cg$table cg$table_type;
|
|
|
|
TYPE cg$tableind_type IS TABLE OF cg$ind_type
|
|
INDEX BY BINARY_INTEGER;
|
|
cg$tableind cg$tableind_type;
|
|
idx BINARY_INTEGER := 1;
|
|
|
|
PROCEDURE ins(cg$rec IN OUT cg$row_type,
|
|
cg$ind IN OUT cg$ind_type,
|
|
do_ins IN BOOLEAN DEFAULT TRUE
|
|
);
|
|
PROCEDURE upd(cg$rec IN OUT cg$row_type,
|
|
cg$ind IN OUT cg$ind_type,
|
|
do_upd IN BOOLEAN DEFAULT TRUE,
|
|
cg$pk IN cg$row_type DEFAULT NULL
|
|
);
|
|
PROCEDURE del(cg$pk IN cg$pk_type,
|
|
do_del IN BOOLEAN DEFAULT TRUE
|
|
);
|
|
PROCEDURE lck(cg$old_rec IN cg$row_type,
|
|
cg$old_ind IN cg$ind_type,
|
|
nowait_flag IN BOOLEAN DEFAULT TRUE
|
|
);
|
|
PROCEDURE slct(cg$sel_rec IN OUT cg$row_type);
|
|
|
|
PROCEDURE validate_arc(cg$rec IN OUT cg$row_type);
|
|
|
|
PROCEDURE validate_domain(cg$rec IN OUT cg$row_type,
|
|
cg$ind IN cg$ind_type DEFAULT cg$ind_true);
|
|
|
|
PROCEDURE validate_foreign_keys_ins(cg$rec IN cg$row_type);
|
|
PROCEDURE validate_foreign_keys_upd(cg$rec IN cg$row_type,
|
|
cg$old_rec IN cg$row_type,
|
|
cg$ind IN cg$ind_type);
|
|
PROCEDURE validate_foreign_keys_del(cg$rec IN cg$row_type);
|
|
|
|
PROCEDURE validate_domain_cascade_delete(cg$old_rec IN cg$row_type);
|
|
PROCEDURE validate_domain_cascade_update(cg$old_rec IN cg$row_type);
|
|
|
|
PROCEDURE cascade_update(cg$new_rec IN OUT cg$row_type,
|
|
cg$old_rec IN cg$row_type );
|
|
PROCEDURE domain_cascade_update(cg$new_rec IN OUT cg$row_type,
|
|
cg$new_ind IN OUT cg$ind_type,
|
|
cg$old_rec IN cg$row_type);
|
|
PROCEDURE domain_cascade_upd( cg$rec IN OUT cg$row_type,
|
|
cg$ind IN OUT cg$ind_type,
|
|
cg$old_rec IN cg$row_type);
|
|
|
|
PROCEDURE cascade_delete(cg$old_rec IN OUT cg$row_type);
|
|
PROCEDURE domain_cascade_delete(cg$old_rec IN cg$row_type);
|
|
|
|
PROCEDURE upd_denorm2( cg$rec IN cg$row_type,
|
|
cg$ind IN cg$ind_type );
|
|
PROCEDURE upd_oper_denorm2( cg$rec IN cg$row_type,
|
|
cg$old_rec IN cg$row_type,
|
|
cg$ind IN cg$ind_type,
|
|
operation IN VARCHAR2 DEFAULT 'UPD' );
|
|
END cg$NETWORK_POINT_MAPPINGS;
|
|
/
|