__IF_EXISTS__
SELECT 1
  FROM CI_UT_INSTL_DTL
 WHERE SCRIPT_FILE_NAME = 'FW420_APDATA3.SQL'
   AND END_DTTM IS NOT NULL
/
__THEN__

__EXIT__

__ENDIF__

__IF_EXISTS__
SELECT 1
  FROM CI_INSTALL_PROD
 WHERE INSTALL_OPT_ID = '11111'
   AND OWNER_FLG = 'F1'
/
__ELSE__

__EXIT__

__ENDIF__




__IF_EXISTS__
SELECT 1
  FROM F1_INSTALLATION
 WHERE SUBSTR(OWNER_FLG,2,1) = '1'
/
__ELSE__

__EXIT__

__ENDIF__


UPDATE CI_DISP_ICON
SET OWNER_FLG = (SELECT OWNER_FLG FROM F1_INSTALLATION)
WHERE DISP_ICON_CD IN ('ACCT','ACCTINFO','BILL' ,'BILLCORR','BILLFACT' ,'BILLMSG' ,'FA' ,'METER' ,'PAYEVENT' ,'PERCHILD' ,'PERPAREN' ,'PERSON' ,'PREMISE' 
,'RATECOMP' ,'RATESCHD' ,'RATEVER' ,'REGRULE' ,'SA' ,'SP' ,'SQRULE' ,'STMT' ,'STMTC' ,'STMTCD' )
AND OWNER_FLG = 'F1'
/


UPDATE CI_DISP_ICON_L
SET OWNER_FLG = (SELECT OWNER_FLG FROM F1_INSTALLATION)
WHERE DISP_ICON_CD IN ('ACCT','ACCTINFO','BILL' ,'BILLCORR' ,'BILLFACT','BILLMSG' ,'FA' ,'METER' ,'PAYEVENT' ,'PERCHILD' ,'PERPAREN' ,'PERSON' ,'PREMISE','RATECOMP' ,'RATESCHD' ,'RATEVER' ,'REGRULE' ,'SA','SP' ,'SQRULE' ,'STMT' ,'STMTC' ,'STMTCD' )
AND OWNER_FLG = 'F1'
/



