/**Begin D:\PDM_UPGRADE\PDM1\FPM_constraint.sql **/
EXEC P_ALTERPK 'PK_T_FPM_EXECBIASANALYS', 'T_FPM_EXECBIASANALYS', 'FID', '1';

IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_FPM_EXECBIASANALYS') CREATE INDEX IDX_FPM_EXECBIASANALYS ON T_FPM_EXECBIASANALYS ( FBILLNO );

IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_EXECBIASANALYS_ORG') CREATE INDEX IDX_EXECBIASANALYS_ORG ON T_FPM_EXECBIASANALYS ( FREPORTORGID );

IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_EXECBIASANALYS_PERIOD') CREATE INDEX IDX_EXECBIASANALYS_PERIOD ON T_FPM_EXECBIASANALYS ( FREPORTPERIODID );


EXEC P_ALTERPK 'PK_T_FPM_EXECBIASANALYS_L', 'T_FPM_EXECBIASANALYS_L', 'FPKID', '1';

IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_FPM_EXECBIASANALYS_L') CREATE INDEX IDX_FPM_EXECBIASANALYS_L ON T_FPM_EXECBIASANALYS_L ( FID );



/**End D:\PDM_UPGRADE\PDM1\FPM_constraint.sql **/
