I’ve resolved this exact issue multiple times. Let me provide the complete solution addressing all three areas you need to fix.
Material Master Extension Registration:
First, ensure your custom attributes are properly registered in the MRP integration layer. Open the Advanced Planning configuration console and navigate to Material Master Extensions. Your custom fields (supplier_lead_time and min_order_qty) must be registered here with these properties:
- Field Type: INTEGER for lead time, DECIMAL for quantity
- Sync Enabled: TRUE
- Include in BOM Interface: TRUE
- Validation Rule: NOT NULL if these are required fields
If these aren’t registered, the MRP engine ignores them completely during BOM sync.
BOM Interface Mapping Update:
Next, update your BOM interface mapping to include the extension table. Edit the file config/interfaces/bom_interface_mapping.xml. Locate the material master query section and modify it:
<!-- Original query -->
<query name="materialMaster">
SELECT m.material_id, m.description, m.unit_of_measure
FROM material_master m
WHERE m.active = 1
</query>
<!-- Updated with extension -->
<query name="materialMaster">
SELECT m.material_id, m.description, m.unit_of_measure,
e.supplier_lead_time, e.min_order_qty
FROM material_master m
LEFT JOIN material_master_ext e ON m.material_id = e.material_id
WHERE m.active = 1
</query>
The LEFT JOIN is critical because not all materials may have extension data yet. Using INNER JOIN would exclude materials without extensions and cause the sync to fail.
Add the field mappings in the same XML file:
<field-mapping>
<source>supplier_lead_time</source>
<target>leadTime</target>
<type>integer</type>
</field-mapping>
<field-mapping>
<source>min_order_qty</source>
<target>minOrderQuantity</target>
<type>decimal</type>
</field-mapping>
MRP Integration Log Analysis:
For the specific error you’re seeing (Material MM-12345 not found), this indicates the material exists in the BOM but not in the material master query result. Enable detailed MRP integration logging:
Edit config/logging.properties:
com.honeywell.mes.planning.integration=DEBUG
com.honeywell.mes.planning.bom.sync=TRACE
Rerun the MRP process and examine the logs. Look for:
- Material master query execution with row count
- BOM component lookup attempts
- Missing material IDs list
If materials are still missing after the interface update, it usually means:
- The extension table has NULL material_id values (data integrity issue)
- The material master query has filters excluding certain materials
- The BOM references inactive or deleted materials
Run this validation query to identify problematic materials:
SELECT b.material_id, m.material_id as master_exists, e.material_id as ext_exists
FROM bom_components b
LEFT JOIN material_master m ON b.material_id = m.material_id
LEFT JOIN material_master_ext e ON b.material_id = e.material_id
WHERE m.material_id IS NULL OR e.material_id IS NULL;
Any rows returned need attention. Either add missing extension records or fix the material master data.
After making these changes:
- Reload the interface configuration (Admin Console > Interfaces > Reload BOM Interface)
- Clear the MRP cache (Advanced Planning > Cache Management > Clear All)
- Run a test MRP calculation on a single work order first
- Check the integration logs for successful material lookups
- Once confirmed working, run full MRP
The BOM sync should complete successfully once all three areas are properly configured.