
IF EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_PERM_ROLE' AND KSQL_COL_NAME ='FDIMTYPEID') 
UPDATE T_PERM_ROLE SET FDIMTYPEID = '0QAIZAG1NEG8' WHERE FDIMTYPEID = 'DIM_BCM_MODEL' AND FBIZDOMAINID = '/G4ZXY9/MISN';

UPDATE t_perm_rolepermdetial  SET FENTITYTYPEID = 'epm_model' WHERE FENTITYTYPEID = 'bcm_model' AND FBIZAPPID = '/G4ZXY9/MISN';
UPDATE t_perm_rolepermdetial  SET FENTITYTYPEID = 'eb_dimensionmanagerlist' WHERE FENTITYTYPEID = 'bcm_dimensionmanager' AND FBIZAPPID = '/G4ZXY9/MISN';


UPDATE t_perm_rolepermdetial  SET FENTITYTYPEID = 'eb_templatelist_bg' WHERE FENTITYTYPEID = 'bcm_templatelist' AND FBIZAPPID = '/G4ZXY9/MISN';
UPDATE t_perm_rolepermdetial  SET FENTITYTYPEID = 'eb_report_list' WHERE FENTITYTYPEID = 'bcm_eb_report_list' AND FBIZAPPID = '/G4ZXY9/MISN';
UPDATE t_perm_rolepermdetial  SET FENTITYTYPEID = 'eb_report_search' WHERE FENTITYTYPEID = 'bcm_report_search' AND FBIZAPPID = '/G4ZXY9/MISN';

UPDATE t_perm_userpermdetail  SET FENTITYTYPEID = 'epm_model' WHERE FENTITYTYPEID = 'bcm_model' AND FBIZAPPID = '/G4ZXY9/MISN';
UPDATE t_perm_userpermdetail  SET FENTITYTYPEID = 'eb_dimensionmanagerlist' WHERE FENTITYTYPEID = 'bcm_dimensionmanager' AND FBIZAPPID = '/G4ZXY9/MISN';


UPDATE t_perm_userpermdetail  SET FENTITYTYPEID = 'eb_templatelist_bg' WHERE FENTITYTYPEID = 'bcm_templatelist' AND FBIZAPPID = '/G4ZXY9/MISN';
UPDATE t_perm_userpermdetail  SET FENTITYTYPEID = 'eb_report_list' WHERE FENTITYTYPEID = 'bcm_eb_report_list' AND FBIZAPPID = '/G4ZXY9/MISN';
UPDATE t_perm_userpermdetail  SET FENTITYTYPEID = 'eb_report_search' WHERE FENTITYTYPEID = 'bcm_report_search' AND FBIZAPPID = '/G4ZXY9/MISN';




