Dynamics 365 – Business Process Flow (BPM) Not Appearing on Records

For those of you who have already done so or plan to migrate to Dynamics 365, there appears to be a bug with business process flows whereby they won’t appear on records. I’ve seen reports this is now fixed for online deployments but unfortunately there’s no such luck for those of us on-premise.

In this article I will hopefully fix the problem for you.

The Problem

When migrating, the BPF’s should have a field called ‘Unique Name’ populated as it is a required field however this doesn’t happen which breaks the BPF’s. As I’ve shown below.


There is also a column in the SQL database called BusinessProcessType which also has a null value which should be set to 0.

The Fix

To fix this we need to in some way populate the fields, I’ve seen reports of some being able to simply deactivate then reactivate the processes to get this to populate so try that first and if it works then great otherwise follow the steps below which were first covered in detail on Jiří Pešík’s blog (I’ve attempted to provide clear instructions and a SQL script to fix the problem for you below) to update the SQL database directly.

This can potentially damage your CRM database so back up first.

  1. Access the SQL server for your CRM deployment.
  2. Open SQL Management Studio and connect to the database.
  3. Click ‘New Query’ and then query for the following making sure to replace ‘OrgName_MSCRM’ with the correct database  –
    SELECT [Name], [Description], [BusinessProcessType], [UniqueName]
    FROM [OrgName_MSCRM].[dbo].[Workflow]
    WHERE Category = 4 and
    UniqueName IS NULL or
    Category = 4 and
    BusinessProcessType Is NULL
  4. This query will find all affected Business Process Flows and display them. Affected BPF’s can be identified by UniqueName and BusinessProcessType being set to Null which causes the issue.BPFIssue3
  5. Now run the following query which will modify all affected BPF’s, changing BusinessProcessType to 0 and generating a UniqueName from a prefix + WorkflowID similar to the standard UniqueName’s value (Be sure to change ‘OrgName’ and the prefix ‘SPCRM’ as required) –
    USE [OrgName_MSCRM]
    UPDATE dbo.Workflow
    SET [BusinessProcessType] = 0, [UniqueName] = 'SPCRM_bpf_' + replace(cast([WorkflowId] as char(36)), '-', '')
    WHERE [Category] = 4 and [UniqueName] IS NULL or [Category] = 4 and [BusinessProcessType] Is NULL
  6. If you now open one of the affected BPF’s you should see the Name field is now populated similar to below – BPFIssue4.PNG
  7. All affected records should now display the Business Process Flow correctly –BPFIssue5.PNG

Hopefully this has helped a few people, if so please leave a comment below and don’t hesitate to suggest anything else you want me to cover.


5 thoughts on “Dynamics 365 – Business Process Flow (BPM) Not Appearing on Records

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.