删除framework 的sql

SELECT APPLICATION_ID  FROM GCFW_APPLICATION WHERE NAME = 'GCTH'; 2745
       select *  from gcfw_framework where  applic
ation_id = 2745  and name = p_framework_name ;
     
       DELETE FROM GCFW_APPLICATION_PROPERTY where APPLICATION_ID = LV_APP_ID;
       DELETE FROM GCFW_COMPONENT_PROPERTY WHERE COMPONENT_ID IN (SELECT COMPONENT_ID FROM GCFW_COMPONENT WHERE FRAMEWORK_ID in (4185,4217,4206));
       DELETE FROM GCFW_HANDLE_TRANSACTION WHERE FRAMEWORK_ID in (4185,4217,4206);
       DELETE FROM GCFW_COMPONENT WHERE FRAMEWORK_ID in (4185,4217,4206);
DELETE FROM GCFW_FRAMEWORK_PROPERTY WHERE FRAMEWORK_ID in (4185,4217,4206);
       DELETE FROM GCFW_FRAMEWORK WHERE FRAMEWORK_ID in (4185,4217,4206);




select * from opgcep2.gcfw_component where name = 'incomeRemediationResponsePlatform'
delete from opgcep2.gcfw_component where name = 'incomeRemediationResponsePlatform'

delete FROM GCFW_COMPONENT_PROPERTY  WHERE COMPONENT_ID = 455380
delete from opgcep2.gcfw_component  WHERE COMPONENT_ID = 455380

select * from opgcep2.gcfw_component where name = 'IDFRPostBackQueueLis'
delete from  GCFW_COMPONENT_PROPERTY where component_id = 455263
delete from opgcep2.gcfw_component where name = 'IDFRPostBackQueueLis'



---------------------
DELETE FROM GCFW_APPLICATION_PROPERTY where APPLICATION_ID = LV_APP_ID;
       DELETE FROM opgcep2.GCFW_COMPONENT_PROPERTY WHERE COMPONENT_ID IN (SELECT COMPONENT_ID FROM opgcep2.GCFW_COMPONENT WHERE FRAMEWORK_ID in ( select framework_id from opgcep2.gcfw_framework where framework_id <= 4221));
       DELETE FROM opgcep2.GCFW_HANDLE_TRANSACTION WHERE FRAMEWORK_ID in ( select framework_id from opgcep2.gcfw_framework where framework_id <= 4221);
       DELETE FROM opgcep2.GCFW_COMPONENT WHERE FRAMEWORK_ID in ( select framework_id from opgcep2.gcfw_framework where framework_id <= 4221);
DELETE FROM opgcep2.GCFW_FRAMEWORK_PROPERTY WHERE FRAMEWORK_ID in ( select framework_id from opgcep2.gcfw_framework where framework_id <= 4221);
       DELETE FROM opgcep2.GCFW_FRAMEWORK WHERE FRAMEWORK_ID in ( select framework_id from opgcep2.gcfw_framework where framework_id <= 4221);
   

你可能感兴趣的:(DB)