/**Begin E:\NextERP_PDM\PDM_UPGRADE\PDMS\branch_lastest\pdm\SYS_constraint.sql **/

 EXEC P_ALTERPK 'PK_T_BOTP_CONVERTRULEVER', 'T_BOTP_CONVERTRULEVER', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_TABNAME = 'T_BOTP_CONVERTRULEVER' AND KSQL_INDNAME = 'IDX_BOTP_CONVERTRULEVER_N') CREATE INDEX IDX_BOTP_CONVERTRULEVER_N ON T_BOTP_CONVERTRULEVER ( FNUMBER );


 EXEC P_ALTERPK 'PK_T_BOTP_CONVERTRULEVER_L', 'T_BOTP_CONVERTRULEVER_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_TABNAME = 'T_BOTP_CONVERTRULEVER_L' AND KSQL_INDNAME = 'IDX_BOTP_CONVERTRULEVER_L') CREATE INDEX IDX_BOTP_CONVERTRULEVER_L ON T_BOTP_CONVERTRULEVER_L ( FID ,FLOCALEID );


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