557: if(regid_proc = true) then
558: insert into hz_application_trans_gt(app_id,party_id) select 694, temp.party_id from hz_purge_gt temp where
559:
560:
561: exists (select 'Y' from PRP_PROPOSALS xx where xx.PARTY_ID = temp.party_id
562: );
563: else
564: delete from hz_purge_gt temp where
565:
563: else
564: delete from hz_purge_gt temp where
565:
566:
567: exists (select 'Y' from PRP_PROPOSALS xx where xx.PARTY_ID = temp.party_id
568: );
569: end if;
570:
571:
3670: delete /*+ parallel(temp) */ from hz_purge_gt temp where
3671: temp.party_id in (select /*+ parallel(xx)*/ xx.PARTY_ID from PRP_EMAIL_RECIPIENTS xx
3672: );
3673: end if;
3674: --PRP_PROPOSALS;CONTACT_PARTY_ID
3675: appid:=694;
3676: if(regid_proc = true) then
3677: insert into hz_application_trans_gt(app_id,party_id) select 694, temp.party_id from hz_purge_gt temp where not exists(select 'Y' from hz_application_trans_gt appl where appl.app_id = 694 and appl.party_id=temp.party_id) and
3678:
3675: appid:=694;
3676: if(regid_proc = true) then
3677: insert into hz_application_trans_gt(app_id,party_id) select 694, temp.party_id from hz_purge_gt temp where not exists(select 'Y' from hz_application_trans_gt appl where appl.app_id = 694 and appl.party_id=temp.party_id) and
3678:
3679: temp.party_id in (select /*+ parallel(xx)*/ xx.CONTACT_PARTY_ID from PRP_PROPOSALS xx
3680: );
3681: else
3682: delete /*+ parallel(temp) */ from hz_purge_gt temp where
3683: temp.party_id in (select /*+ parallel(xx)*/ xx.CONTACT_PARTY_ID from PRP_PROPOSALS xx
3679: temp.party_id in (select /*+ parallel(xx)*/ xx.CONTACT_PARTY_ID from PRP_PROPOSALS xx
3680: );
3681: else
3682: delete /*+ parallel(temp) */ from hz_purge_gt temp where
3683: temp.party_id in (select /*+ parallel(xx)*/ xx.CONTACT_PARTY_ID from PRP_PROPOSALS xx
3684: );
3685: end if;
3686: --CSI_ITEM_INSTANCES;LOCATION_ID
3687: appid:=542;