/**Begin D:\PDM_UPGRADE\PDM1\FCS_constraint.sql **/
 EXEC P_ALTERPK 'PK_T_FCS_BILLDIMBALANCE_IE', 'T_FCS_BILLDIMBALANCE_IE', 'FENTRYID', '1';

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


 EXEC P_ALTERPK 'PK_T_FCS_BILLDIMBALANCE', 'T_FCS_BILLDIMBALANCE', 'FID', '1';

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


 EXEC P_ALTERPK 'PK_T_FCS_BILLDIMBALANCE_L', 'T_FCS_BILLDIMBALANCE_L', 'FPKID', '1';

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


 EXEC P_ALTERPK 'PK_T_FCS_BILLDIMBALANCE_AE', 'T_FCS_BILLDIMBALANCE_AE', 'FENTRYID', '1';

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


 EXEC P_ALTERPK 'PK_T_FCS_BILLDIMBALANCE_FE', 'T_FCS_BILLDIMBALANCE_FE', 'FENTRYID', '1';

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


 EXEC P_ALTERPK 'PK_T_FCS_BILLDIMBALANCE_BE', 'T_FCS_BILLDIMBALANCE_BE', 'FENTRYID', '1';

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



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