Could not find relationship for related entity field–Error when Exporting Contact Views to Excel

Follow my blog for more interesting topics on Dynamics 365, Portals and Power Platform. For training and consulting, write to us at

This one is quite a shocker. Today my customer called me up and reported that whenever they are trying to export their contact views to excel, they are getting the below error.


I was quite surprised by this and haven’t encountered it so far. I tried to export the ‘Active Contact’ views in Vanilla environment and it just works fine.

Then my next question was – Have you modified the view? The error clearly states that it is unable to find the related column name of Account Entity. And my guess was correct. They have added the Account Name field in the Active Contacts view from the parent Account entity. And they are using the OOB relationship only.

So let’s replicate the step. I also went ahead and modified the Contact View by adding the related column of Account using PoweApps Maker Portal.


Save and publish the view.

And now when I try to export to excel, I too get the error.


Well this is new. So I decided to debug a little further. I opened Advanced Find and I download the Fetchxml.


In the fetchxml I could the same alias as mentioned in the error. So I was quite sure that while the query is fine, the layoutxml as suggested by the error, is the issue. If I tried to execute the results of the advanced find, I got this error.


Then I opened up the view in classic editor. And below is what I see.


Surely something have gone horribly wrong while I added the related entity field in PowerApps Maker Portal. I removed the field and added the account name field back. Saved and published the changes. And now when I tried to download it worked fine.

So as of now if you are getting this error, no need to worry. Open the view in classic editor and then remove the column which is throwing error and add it back. The classic editor will save your day like so many old time in the past.

Alright, that solves the problem but I wanted to do a further deep dive. Is the issue with maker portal. Below is what I tried.

  • Create a relationship with Custom entity and add the custom entity related field – Worked
  • Use the Primary contact fields in the Accounts View – Worked
  • Used a custom relationship between Account and Contact and used the related account fields on Contact View – Worked

So as per my research, this is something related to the contact views and when you try to add a related field from the Account entity using OOB relationship. Not sure when this bug got introduced. Till then it gets fixed or you find a better way, use the workaround as mentioned in the blog.

Hope this helps

Debajit Dutta

(Business Solutions MVP)

Leave a Reply