/**Begin D:\PDM_UPGRADE\PDM1\FCS_constraint.sql **/
 EXEC P_ALTERPK 'PK_T_FCS_TASKFLOW', 'T_FCS_TASKFLOW', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_T_FCS_TASKFLOW') CREATE INDEX IDX_T_FCS_TASKFLOW ON T_FCS_TASKFLOW ( FENABLE ,FBIZENTITYID ,FBEGINOPERATE );


 EXEC P_ALTERPK 'PK_T_FCS_TASKFLOW_L', 'T_FCS_TASKFLOW_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_T_FCS_TASKFLOW_L') CREATE INDEX IDX_T_FCS_TASKFLOW_L ON T_FCS_TASKFLOW_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_T_FCS_TASKFLOW_ORG', 'T_FCS_TASKFLOW_ORG', 'FENTRYID', '1';

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


 EXEC P_ALTERPK 'PK_T_FCS_TASKFLOW_TASK', 'T_FCS_TASKFLOW_TASK', 'FENTRYID', '1';

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


 EXEC P_ALTERPK 'PK_T_FCS_TASKEXESUM_LOG', 'T_FCS_TASKEXESUM_LOG', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_T_FCS_TASKEXESUM_LOG') CREATE INDEX IDX_T_FCS_TASKEXESUM_LOG ON T_FCS_TASKEXESUM_LOG ( FSUMLOGID );


 EXEC P_ALTERPK 'PK_T_FCS_TASKEXEDETAIL_LOG', 'T_FCS_TASKEXEDETAIL_LOG', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_T_FCS_TASKEXEDETAIL_LOG') CREATE INDEX IDX_T_FCS_TASKEXEDETAIL_LOG ON T_FCS_TASKEXEDETAIL_LOG ( FSUMLOGID );



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