/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\TCCIT_constraint.sql **/
 EXEC P_ALTERPK 'PK_TCCIT_DG_A100000_7_DET', 'T_TCCIT_DG_A100000_7_DET', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_DG_A100000_7_DET') CREATE INDEX IDX_TCCIT_DG_A100000_7_DET ON T_TCCIT_DG_A100000_7_DET ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_DG_A100000_7_SUM', 'T_TCCIT_DG_A100000_7_SUM', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_DG_A100000_7_SUM') CREATE INDEX IDX_TCCIT_DG_A100000_7_SUM ON T_TCCIT_DG_A100000_7_SUM ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_DKYNSSDE_AJUST', 'T_TCCIT_DKYNSSDE_AJUST', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_DKYNSSDE_AJUST') CREATE INDEX IDX_TCCIT_DKYNSSDE_AJUST ON T_TCCIT_DKYNSSDE_AJUST ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_DG_ASSET_ADJUST', 'T_TCCIT_DG_ASSET_ADJUST', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_DG_ASSET_ADJUST') CREATE INDEX IDX_TCCIT_DG_ASSET_ADJUST ON T_TCCIT_DG_ASSET_ADJUST ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_DG_DEDUCT_ADJUST', 'T_TCCIT_DG_DEDUCT_ADJUST', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_DG_DEDUCT_ADJUST') CREATE INDEX IDX_TCCIT_DG_DEDUCT_ADJUST ON T_TCCIT_DG_DEDUCT_ADJUST ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_DG_INCOME_ADJUST', 'T_TCCIT_DG_INCOME_ADJUST', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_DG_INCOME_ADJUST') CREATE INDEX IDX_TCCIT_DG_INCOME_ADJUST ON T_TCCIT_DG_INCOME_ADJUST ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_SOFT_IC_JB_SUM', 'T_TCCIT_SOFT_IC_JB_SUM', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_SOFT_IC_JB_SUM') CREATE INDEX IDX_TCCIT_SOFT_IC_JB_SUM ON T_TCCIT_SOFT_IC_JB_SUM ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_SOFT_IC_SUM', 'T_TCCIT_SOFT_IC_SUM', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_SOFT_IC_SUM') CREATE INDEX IDX_TCCIT_SOFT_IC_SUM ON T_TCCIT_SOFT_IC_SUM ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_SOFT_IC_YG_SUM', 'T_TCCIT_SOFT_IC_YG_SUM', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_SOFT_IC_YG_SUM') CREATE INDEX IDX_TCCIT_SOFT_IC_YG_SUM ON T_TCCIT_SOFT_IC_YG_SUM ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_HZDG_MSJJ_SUM', 'T_TCCIT_HZDG_MSJJ_SUM', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_HZDG_MSJJ_SUM') CREATE INDEX IDX_TCCIT_HZDG_MSJJ_SUM ON T_TCCIT_HZDG_MSJJ_SUM ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_HZDG_QTTZ_SUM', 'T_TCCIT_HZDG_QTTZ_SUM', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_HZDG_QTTZ_SUM') CREATE INDEX IDX_TCCIT_HZDG_QTTZ_SUM ON T_TCCIT_HZDG_QTTZ_SUM ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_DOMESTIC_ADJUST', 'T_TCCIT_DOMESTIC_ADJUST', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_DOMESTIC_ADJUST') CREATE INDEX IDX_TCCIT_DOMESTIC_ADJUST ON T_TCCIT_DOMESTIC_ADJUST ( FORGID ,FSKSSQQ ,FSKSSQZ );


 EXEC P_ALTERPK 'PK_TCCIT_SETZ_SEJS_SUM', 'T_TCCIT_SETZ_SEJS_SUM', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TCCIT_SETZ_SEJS_SUM') CREATE INDEX IDX_TCCIT_SETZ_SEJS_SUM ON T_TCCIT_SETZ_SEJS_SUM ( FORGID ,FSKSSQQ ,FSKSSQZ );



/**End E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\TCCIT_constraint.sql **/
