Cost rollup analytics report fails due to missing BOM data in cost management module after recent item structure changes

We’re running into a critical issue with our cost rollup analytics dashboard in Aras 12.0. The report consistently fails when trying to aggregate costs from our BOM structures, throwing errors about missing relationship data.

The problem started after we made some structural changes to our Part BOM relationships last week. When the analytics engine tries to traverse the BOM hierarchy for cost calculations, it encounters null references:

<Item type="Part" action="get">
  <Relationships>
    <Item type="Part BOM" select="quantity,cost">
      Error: Related item is null
    </Item>
  </Relationships>
</Item>

The BOM relationships appear valid in the UI, but the cost rollup query can’t find them. We need to understand if this is a BOM relationship validation issue or if our structure changes broke the data integrity that the analytics depend on. Has anyone dealt with cost analytics failing after BOM restructuring?

Your issue involves all three focus areas: BOM relationship validation, cost rollup analytics configuration, and data integrity after structural changes. Here’s a comprehensive solution:

BOM Relationship Validation: First, fix the null source_id references. Run this AML query to identify all broken relationships:

<AML>
  <Item type="Part BOM" action="get">
    <source_id condition="is null"></source_id>
  </Item>
</AML>

For each broken relationship, you need to update the source_id to point to the correct parent Part. If you have many relationships to fix, create a server method to batch update them:

var bomItem = inn.getItemByKeyedName("Part BOM", bomId);
bomItem.setProperty("source_id", parentPartId);
bomItem.apply();

Cost Rollup Analytics: Verify your Cost Rollup Settings include Part BOM as a valid relationship type. Navigate to Administration > Cost Management > Cost Rollup Settings and ensure the relationship_type property includes your Part BOM type. If missing, add it and save.

Next, clear the analytics cache to force a fresh calculation:

  • Stop the Aras Innovator server
  • Clear the cache directory: /Innovator/Server/cache/
  • Restart and rebuild the cost analytics index

Data Integrity After Structure Changes: Implement a validation routine that runs after any BOM restructuring. Create a server event on Part BOM that validates:

  1. source_id is not null and points to valid Part
  2. related_id is not null and points to valid child Part
  3. Relationship is in appropriate lifecycle state (Released/Production for analytics)
  4. No circular references exist in the BOM hierarchy

Add this validation as an onBeforeAdd and onBeforeUpdate event. This prevents future analytics failures by catching data integrity issues at the point of creation.

For your immediate problem: fix the null source_id values, promote Preliminary relationships to Released state, clear the server cache, and rerun your cost rollup analytics. The report should process successfully once the relationship integrity is restored.

Consider also adding a scheduled workflow that periodically validates BOM relationship integrity and sends alerts if issues are detected. This provides early warning before analytics reports fail.

The null source_id values are your smoking gun. When you delete and recreate BOM relationships, you need to ensure the source_id properly links back to the parent Part. This is especially critical for cost analytics because the rollup algorithm walks the entire BOM tree using those source references. If any link in the chain has a null source_id, the traversal breaks and you get exactly the error you’re seeing. The Preliminary lifecycle state will also block analytics processing in most standard configurations.

I’d recommend implementing a BOM validation method that runs before your cost analytics to catch these issues proactively. You can create a server method that validates all relationship integrity before the rollup executes. This way you get clear error messages about which specific relationships have problems rather than cryptic null reference errors from the analytics engine.

Adding to what others said - you also need to verify your cost rollup configuration hasn’t been affected by the restructure. Check the Cost Rollup Settings item type to ensure your BOM relationship type is still properly configured as a rollup source.

What type of structural changes did you make? If you deleted and recreated BOM relationships instead of updating them, the analytics queries might still be referencing the old relationship IDs. The cost rollup engine caches relationship paths, and those cache entries don’t automatically update when you restructure. You might need to clear the server cache and rebuild the cost analytics index. Also check if your BOM relationships are in the correct lifecycle state - the analytics engine typically only processes relationships in Released or Production states.

I’ve seen similar issues with cost analytics after BOM changes. First check if your Part BOM relationships have the proper source_id references. Sometimes after restructuring, the relationship items exist but the source_id field gets corrupted. Run a quick query in Nash to validate the relationship integrity before diving deeper into the analytics configuration.