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

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


 EXEC P_ALTERPK 'PK_TCCIT_SALARY_SUMMARY_DG', 'T_TCCIT_SALARY_SUMMARY_DG', 'FID', '1';

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


 EXEC P_ALTERPK 'PK_TCCIT_ASSETS_DETAIL', 'T_TCCIT_ASSETS_DETAIL', 'FID', '1';

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


 EXEC P_ALTERPK 'PK_TCCIT_ASSETS_SUMMARY', 'T_TCCIT_ASSETS_SUMMARY', 'FID', '1';

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


 EXEC P_ALTERPK 'PK_TCCIT_RIGHT_INCOME_SUM', 'T_TCCIT_RIGHT_INCOME_SUM', 'FID', '1';

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


 EXEC P_ALTERPK 'PK_TCCIT_RIGHTS_INCOME_DET', 'T_TCCIT_RIGHTS_INCOME_DET', 'FID', '1';

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


 EXEC P_ALTERPK 'PK_TCCIT_SALE_ZKZRTH_SUM', 'T_TCCIT_SALE_ZKZRTH_SUM', 'FID', '1';

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


 EXEC P_ALTERPK 'PK_TCCIT_ZKZRTH_TZ_DETAIL', 'T_TCCIT_ZKZRTH_TZ_DETAIL', 'FID', '1';

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



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