/**Begin D:\PDM_UPGRADE\PDM1\TM_constraint.sql **/
 EXEC P_ALTERPK 'PK_TM_REQLIMIT', 'T_TM_REQLIMIT', 'FID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TM_REQNOTE_LIMIT') CREATE  CLUSTERED INDEX IDX_TM_REQNOTE_LIMIT ON T_TM_REQLIMIT ( FBILLNO ,FBILLSTATUS );


 EXEC P_ALTERPK 'PK_TM_REQLIMIT_PRD', 'T_TM_REQLIMIT_PRD', 'FPKID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TM_PRD_LIMIT') CREATE  CLUSTERED INDEX IDX_TM_PRD_LIMIT ON T_TM_REQLIMIT_PRD ( FID );


 EXEC P_ALTERPK 'PK_TM_REQLIMIT_L', 'T_TM_REQLIMIT_L', 'FPKID', '0';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TM_REQNOTE_LIMIT_L') CREATE  CLUSTERED INDEX IDX_TM_REQNOTE_LIMIT_L ON T_TM_REQLIMIT_L ( FID );



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