/**Begin D:\PDM_UPGRADE\pdm1\INLEVEL_constraint.sql **/
 EXEC P_ALTERPK 'PK_MSPLAN_INVLEVEL', 'T_MSPLAN_INVLEVEL', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_MSPLAN_INVLEVEL_NUM') CREATE INDEX IDX_MSPLAN_INVLEVEL_NUM ON T_MSPLAN_INVLEVEL ( FNUMBER );


 EXEC P_ALTERPK 'PK_T_MSPLAN_INVLEVEL_L', 'T_MSPLAN_INVLEVEL_L', 'FPKID', '1';

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


 EXEC P_ALTERPK 'PK_MSPLAN_INVLEVELENTRY', 'T_MSPLAN_INVLEVELENTRY', 'FENTRYID', '1';

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


/**End D:\PDM_UPGRADE\pdm1\INLEVEL_constraint.sql **/
