Posts in Category: crm 2015

Database Errors on Restore into v9

If you’re getting ready to perform an on-premise update by importing new organizations into your existing tenant you might start to get some cryptic database errors on constraints.

The constraints themselves vary, mine was in reference to cndx_PrimaryKey_DiscountType, others I’ve seen were in relation to opportunities.

Whatever the error, you will need to install the 0.3 update to address and fix the issue so you can import the tenant.

When you install the server, this update is not applied by “Getting updates”.

The link to the patch is located here – https://support.microsoft.com/en-us/help/4490599/service-update-0-3-for-microsoft-dynamics-365-9-0 – once done, your upgrade and import will succeed.

Read More


The Simplest Dynamics Feature Request

This post is going to have no code and might sound a bit preachy, but I have to get this off my chest because it keeps rearing it’s ugly head.

The new features existing and coming into Dynamics365 are great.  I’ve been spending the last few weeks catching up on some sessions from last year’s Ignite and working with some new features I haven’t had much time for in the past six months.

They are all great and you can see a direction the product is entering.

But here I am, working with a customer to increase their level of adoption with Dynamics inside their company (some rogue groups, it happens, we’ve all been there) and the one thing they ask for…

Can we setup default dashboards for users, groups or teams?

Can we default

Read More


Bad SDK Error Messages

I love getting these error messages when using the Dynamics SDK!error.PNG

I immediately know where to go to resolve the problem when it happens 🙁

If you are trying to diagnose precisely where the issue is in your code, the “Reason” member won’t have this data – probably because it’s not at the top of the stack and you need to dig deep to see what’s what.

To get to the nitty gritty of what is happening you will need to dig into the InnerFault of the Detail member to see what has really happened.

Read More


Working with Business Units and the SDK

When deploying solutions, you can’t include Business Units in your solution file and if you are needing to create many of them, this can be a bit of a hassle.

I recently had this problem where I was working on a project that had many units that I didn’t want to create manually, so I turned my eyes to the SDK in order to take this task from 20 minutes to 1.

The Parent Business Unit

The most important thing with Business Units is to remember their hierarchy.  Irrespective of how you have setup your system, you will always have a top-level unit that everything else inherits from.

When trying to find this unit (to then extend from) all you need to do is query for the businessunit that does not have a parent

Read More


Accessing Dynamics Queues Programmatically

I typically still code in Dynamics using LateBound requests.  There have been a few instances where I have switched to Early Bound but I continue to do this for the following reasons

  1. I don’t like dragging around proxies into my code that can change environment to environment.
  2. When not depending on proxies, I feel have more options to downgrade my code into different versions based on what can be discovered.
  3. I get to learn about all the hidden relationships between entities and attributes that gives me a deeper understanding of what lies beneath.

With that said, this week I needed to access some queues in Dynamics and see what was in them.

To do this, I queried Dynamics for my queue based on the name provided.

QueryExpression query = new QueryExpression();
query.EntityName = "queue";
query.ColumnSet = new ColumnSet(true);
query.Criteria.AddCondition("name",															

Read More