Trigger Debugging

Hi all,

I'm attempting to debug a trigger, but I'm unable to see the value of any variables within it.
If I add the variable to the "Watches" window, it just tells me "(not a variable)"...
Any idea what I can do to view the contents of the variable.
NOTE: It is not a :new or :old variable, andI've tried it with several other variables in the trigger, but can't get the value out of any of them....

Any suggestions would be greatly appreciated.

Best Regards,

David
 
Hi,
this is all the code from my trigger:

CREATE OR REPLACE TRIGGER TRMULTIRECPOST_ADDRESS
AFTER INSERT OR UPDATE OR DELETE ON ADDRESS

DECLARE
TYPE xMembnos IS TABLE of basic.membno%TYPE INDEX BY BINARY_INTEGER;
Membnos xMembnos;
TYPE xRowids IS TABLE of UROWID INDEX BY BINARY_INTEGER;
Rowids xRowids;
vPersonno basic.personno%TYPE;
vRowid UROWID;
vMembno address.membno%TYPE;
vAddnme address.addnme%TYPE;
vAdlin1 address.adlin1%TYPE;
vAdlin2 address.adlin2%TYPE;
vAdlin3 address.adlin3%TYPE;
vAdlin4 address.adlin4%TYPE;
vAdlin5 address.adlin5%TYPE;
vPstcde address.pstcde%TYPE;
vCntry address.cntry%TYPE;
vTelnm1 address.telnm1%TYPE;
vTelnm2 address.telnm2%TYPE;
vAddeff address.addeff%TYPE;
vMailsort address.mailsort%TYPE;
vEmailad address.emailad%TYPE;
vMsres address.msres%TYPE;
i BINARY_INTEGER := 0;
i2 BINARY_INTEGER := 0;
begin
If pkge_multirec.DisableAddressTrigger > 0 Then
RETURN;
END IF;

pkge_multirec.DisableAddressTrigger := 1;

If DELETING Then
FOR i in pkge_multirec.AddressRowids.FIRST..pkge_multirec.AddressRowids.LAST LOOP
select rowid BULK COLLECT into Rowids from address where nmecde = 'MB' and addcde = 'Z1' and exists (select 1 from basic a where a.membno=address.membno and a.personno=vPersonno) and rowid vRowid;
FORALL i2 IN Rowids.FIRST..Rowids.LAST
delete address where rowid = Rowids(i2);
END LOOP;
Else
FOR i in pkge_multirec.AddressRowids.FIRST..pkge_multirec.AddressRowids.LAST LOOP
vPersonno := pkge_multirec.AddressPersonnos(i);
vRowid := pkge_multirec.AddressRowids(i);
select addnme,adlin1,adlin2,adlin3,adlin4,adlin5,pstcde,cntry,telnm1,telnm2,addeff,mailsort,emailad,msres into vAddnme,vAdlin1,vAdlin2,vAdlin3,vAdlin4,vAdlin5,vPstcde,vCntry,vTelnm1,vTelnm2,vAddeff,vMailsort,vEmailad,vMsres from address where rowid = vRowid;
select membno, rowid BULK COLLECT into Membnos, Rowids from address where nmecde = 'MB' and addcde = 'Z1' and exists (select 1 from basic a where a.membno=address.membno and a.personno=vPersonno) and rowid vRowid;
FORALL i2 IN Rowids.FIRST..Rowids.LAST
delete address where rowid = Rowids(i2);
FORALL i2 IN Membnos.FIRST..Membnos.LAST
insert into address (membno,nmecde,addcde,addnme,adlin1,adlin2,adlin3,adlin4,adlin5,pstcde,cntry,telnm1,telnm2,addeff,mailsort,emailad,msres)
values (Membnos(i2),'MB','Z1',vAddnme,vAdlin1,vAdlin2,vAdlin3,vAdlin4,vAdlin5,vPstcde,vCntry,vTelnm1,vTelnm2,vAddeff,vMailsort,vEmailad,vMsres);
Membnos.DELETE;
END LOOP;
pkge_multirec.DisableAddressTrigger := 0;
pkge_multirec.AddressRowids.delete;
pkge_multirec.AddressPersonnos.delete;
pkge_multirec.AddressIndex := 0;
END IF;
END;

Please let me know if you need any more information.

Regards,
David
 
Back
Top