__IF_EXISTS__
SELECT 1
  FROM CI_UT_INSTL_DTL
 WHERE SCRIPT_FILE_NAME = 'FW400_APDATA17.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__


update ci_md_nav
set url_ovrd = substr(URL_OVRD,2)
where rtrim(url_ovrd) is not null
and substr(URL_OVRD,1,1) = '/'
and RTRIM(UPPER(NAVIGATION_KEY)) LIKE '%/_H' ESCAPE '/'
/


update ci_md_nav
set url_ovrd = substr(URL_OVRD,1,INSTR(URL_OVRD,'/',1,1)-1)||'_'||substr(URL_OVRD,INSTR(URL_OVRD,'/',1,1)+1)
where rtrim(url_ovrd) is not null
and INSTR(URL_OVRD,'/',1,1) != 0
and RTRIM(UPPER(NAVIGATION_KEY)) LIKE '%/_H' ESCAPE '/'
/


update ci_md_nav
set url_ovrd = REPLACE(REPLACE(URL_OVRD, '.html#SPLINK', '_'),'&','And')
where rtrim(url_ovrd) is not null
and RTRIM(UPPER(NAVIGATION_KEY)) LIKE '%/_H' ESCAPE '/'
/


update ci_md_nav
set url_ovrd = REPLACE(REPLACE(REPLACE(REPLACE(URL_OVRD, '__' ,'_'), '__' ,'_'), '__' ,'_'), '__' ,'_')
where rtrim(url_ovrd) is not null
and RTRIM(UPPER(NAVIGATION_KEY)) LIKE '%/_H' ESCAPE '/'
/




















