Reputation: 47
I want to update a field without firing the plugin execution. I tried to update it with SQL 4 CDS
from Xrmtoolbox
, but the plugin executes and I get a timeout error. This plugin is updating all child records, but at this case we want to bypass this.
Is there a way to achieve this ?
Upvotes: 1
Views: 1105
Reputation: 47
I found a way to update record without triggering plugins. At SQL 4 CDS, in Settings menu there is an option "Bypass custom plugins" as you can see at the screenshot below. By checking this option, you can update the record without triggering plugin execution
Upvotes: 1
Reputation: 7918
In C# you can actually do this using an UpdateRequest
.
You would create the request like this:
var request = new UpdateRequest
{
Target = entity,
["BypassCustomPluginExecution"] = true
};
Important note: users must have the
prvBypassCustomPlugins
privilege to make this work. This privilege cannot be assigned through the UI and only the System Administrator role has this privilege by default.
See also Bypass Custom Business Logic - MS Learn.
Upvotes: 2