2824: if(regid_proc = true) then
2825: insert into hz_application_trans_gt(app_id,party_id) select 204, temp.party_id from hz_purge_gt temp where
2826:
2827:
2828: exists (select 'Y' from XLE_ENTITY_PROFILES xx where xx.PARTY_ID = temp.party_id
2829: )
2830:
2831: or exists (select 'Y' from XLE_ETB_PROFILES xx where xx.PARTY_ID = temp.party_id
2832: );
2833: else
2834: delete from hz_purge_gt temp where
2835:
2836:
2837: exists (select 'Y' from XLE_ENTITY_PROFILES xx where xx.PARTY_ID = temp.party_id
2838: )
2839:
2840: or exists (select 'Y' from XLE_ETB_PROFILES xx where xx.PARTY_ID = temp.party_id
2841: );