POWEROBJECTS

718 Washington Ave. N. Suite #101
Minneapolis, MN 55401
View map and all Locations

Send us a message

We have identified a fix for a problem that affects upgraded CRM 2016 on-prem environments when using marketing lists and today’s blog will tell you all about it! Let’s jump right in…

cannot add records to marketing lists

Problem

This issue occurs when you open a marketing list, and select “Add Using Advanced Find” or “Evaluate Using Advanced Find.”

Let’s say you select “Add Using Advanced Find,” and then you do your search. After the list of records is returned, you then select the option to add all members returned by the search to the marketing list.

cannot add records to marketing lists

Then you click the “Add to Marketing List” button. Instead of adding your contacts, accounts, or leads to the marketing list, nothing happens, and CRM just spins forever. Eventually you may get an error, but the list is never updated with the members you are trying to add.

You may also find that this particular error only happens when you have auditing turned on.

Cause

This problem is caused by an issue with a stored procedure called p_InsertMultipleAuditRows on the CRM database that is invoked when the button above is clicked to add to the marketing list. When invoked, it uses a variable called @audituseradditionalinfo that it expects to be inserted into the AuditBase table to the UserAdditionalInfo column. However, it is failing to do so, and results in the following error in the SQL server:

“Procedure or function ‘p_InsertMultipleAuditRows’ expects parameter ‘@audituseradditionalinfo’, which was not supplied.”

This results in the CRM side, it never successfully completes the process of adding to the marketing list.

Important Note

We worked with Microsoft to provide a solution to our issue, and they supplied us with a fix which was to alter this specific stored procedure and comment out 3 lines of code, that refer to the column UserAdditionalInfo and the variable @audituseradditionalinfo. This fix will need to be done from someone with with full access to the CRM database, preferably a SQL admin.

WARNING

Making direct changes in SQL is deemed an unsupported change. That means that future updates and considerations done by the Microsoft product team will not take into consideration any unsupported change, and it should be done at your own risk. However, we have had success with the following query, and have not had a need to revert back any of our changes shown below. And as always, recommend doing a full database backup before doing a direct SQL update.

Fix

Did you read and understand our warning above? Good! Now in order to fix our problem, you will need to run the following query against the CRM database. Please copy it exactly as shown below, and run it, so we can correct the faulty stored procedure. It will complete in a second or less.

As soon as it completes, go back to Dynamics 365, and try the same steps, and you should now be able to successfully add to a marketing list.

Happy Dynamics 365’ing!

Avatar for JoeCRM

JoeCRM

Joe CRM is a CRM superhero who runs on pure Microsoft Dynamics CRM adrenaline. As the face of PowerObjects, Joe CRM’s mission is to reveal innovative ways to use Dynamics CRM and bring the application to more businesses and organizations around the world.