Back

Plugin processing Failed : The given key was not preset in the dictionary

Published: Mar 21, 2018
Post Author Written by Ethan Sorenson

Receiving the following error in CRM/D365 Sales ‘System Jobs’

Plugin processing Failed : The given key was not preset in the dictionary

There are two known causes for this error.

Blank Primary Field

This error message can occur when the record that the change plugin was triggered on does not have a value in the primary field.
CRM Primary Field 1

SmartConnect change tracking uses the primary field to link the source record to the change tracking table. If this field is blank the query will fail.

The resolution is to always have a value in your primary field.

Invalid Change Entity
This error can also occur when trying to set a trigger on a detail entity. This includes the following entities.

  • Invoice Product
  • Lead product
  • Opportunity Product
  • Order Product
  • Quote Product

The resolution is to set the trigger on the header entity. The trigger will execute if a line level change is made to any of the above listed entities.
ex. If I want to capture changes to the Invoice Product entity, I would select Invoice as the change entity.

Feeling stuck? Get the support and guidance you need to help you power through any data challenge

We're on your integration team. Connect with our people and let us know how we can help you.