All Downloads are FREE. Search and download functionalities are using the official Maven repository.

expsigladb.Trigger.au_l_ass_comp_doc_cont_nmp.trg Maven / Gradle / Ivy

There is a newer version: 6.6.11
Show newest version
CREATE OR REPLACE TRIGGER AU_L_ASS_COMP_DOC_CONT_NMP AFTER  UPDATE  ON ASS_COMP_DOC_CONT_NMP for each row
DECLARE
lASS_COMP_DOC_CONT_NMP L_ASS_COMP_DOC_CONT_NMP%rowtype;
lTbName varchar2(30);
lUser varchar2(30);
lLogRegistry log_registry%rowtype;
lPG_STORICO number;
begin
--
-- Trigger attivato su  UPDATE  di record da ASS_COMP_DOC_CONT_NMP
--
-- Date: 08/04/2004
-- Version: 1.0
--
-- Dependency:CLASS_COMP_DOC_CONT_NMP
--
-- History:
--
-- Date: 08/04/2004
-- Version: 1.0
-- Creazione
--
-- Body:
  select user into lUser from dual;
  lTbName :='ASS_COMP_DOC_CONT_NMP';
  select nvl(max(PG_STORICO_),0) into lPG_STORICO from L_ASS_COMP_DOC_CONT_NMP;
  lASS_COMP_DOC_CONT_NMP.CD_CDS_COMPENSO := :OLD.CD_CDS_COMPENSO;
  lASS_COMP_DOC_CONT_NMP.ESERCIZIO_COMPENSO := :OLD.ESERCIZIO_COMPENSO;
  lASS_COMP_DOC_CONT_NMP.CD_UO_COMPENSO := :OLD.CD_UO_COMPENSO;
  lASS_COMP_DOC_CONT_NMP.PG_COMPENSO := :OLD.PG_COMPENSO;
  lASS_COMP_DOC_CONT_NMP.CD_CDS_DOC := :OLD.CD_CDS_DOC;
  lASS_COMP_DOC_CONT_NMP.ESERCIZIO_DOC := :OLD.ESERCIZIO_DOC;
  lASS_COMP_DOC_CONT_NMP.PG_DOC := :OLD.PG_DOC;
  lASS_COMP_DOC_CONT_NMP.CD_TIPO_DOC := :OLD.CD_TIPO_DOC;
  lASS_COMP_DOC_CONT_NMP.UTCR := :OLD.UTCR;
  lASS_COMP_DOC_CONT_NMP.UTUV := :OLD.UTUV;
  lASS_COMP_DOC_CONT_NMP.DACR := :OLD.DACR;
  lASS_COMP_DOC_CONT_NMP.DUVA := :OLD.DUVA;
  lASS_COMP_DOC_CONT_NMP.PG_VER_REC := :OLD.PG_VER_REC;
  lASS_COMP_DOC_CONT_NMP.PG_STORICO_ := lPG_STORICO + 1;
  lASS_COMP_DOC_CONT_NMP.USER_ := lUser;
  lASS_COMP_DOC_CONT_NMP.DT_TRANSACTION_ :=  sysdate;
  lASS_COMP_DOC_CONT_NMP.ACTION_ := 'U';
  CLASS_COMP_DOC_CONT_NMP.insertRiga(lTbName,lASS_COMP_DOC_CONT_NMP);
  CLASS_COMP_DOC_CONT_NMP.updateRegistry(lTbName,'U',lUser);
END;
/






© 2015 - 2024 Weber Informatics LLC | Privacy Policy