Skip to main content
Post a question

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Dynamics 365 SharePoint integration for custom entity - failing

Like (0) ShareShare
ReportReport
Posted on 21 Jun 2017 05:49:14 by Microsoft Employee

Hi All,

Wondering if anyone has seen the following set of symptoms before, or even if not any suggestions as to how best to resolve such a problem....

As a result of UI customisations only (no code development), client has a Dynamics implementation with a custom entity which has a lookup relationship with the Account entity. Client has loaded 25000 documents into SharePoint folders based on a tested procedure which automatically created SP folders under the Account SP folders - i.e. Account library/Specific account/custom entity/Specific custom entity record/multi-level folder structure for custom record. This took more than an elapsed week of intermittent effort, basically 100 times approximately 250 records per custom entity record, say.

From Document location records it can be shown that this worked Ok for a while, but unfortunately at some point early on in the week, Dynamics stopped creating the above folder hierarchy automatically, and from that point on automatically created folders in the custom entity's library only, i.e. Custom entity library/Specific custom entity record/multi-level folder structure for custom record.

It is worth noting that automatic folder creation for the Opportunity entity still works as expected.

The client performing the bulk folder uploads that created the multi-level folder structure did not notice the change of behaviour, and now has 25000 documents in the wrong SP library and now cannot see the custom entity's documents through the account records as was required.

And SharePoint Online by design does not support copying or moving such a large number of documents around between libraries, so we are looking for solutions there in order to relocate the documents manually.

Just as an aside using File Explorer view took 7 hours to copy 1.25 GB of documents (only about 400 in number) between these two libraries, and SPFileZilla refused to do the copy because the SharePoint List View threshold (5000 entries in list max) was exceeded when requesting the copy of the 400 documents - I assume that it (and indeed SP Online) is objecting to having to search the whole source library of 25000 documents just to find the 400 to copy at one time.

I have found no way to date of reversing this change of Dynamics behaviour, including creating a brand new SharePoint site and recreating the Dynamics - SP integration with automatic folder creation under the Account entity. My conclusion here is that a setting actually within the custom entity itself is now preventing the custom entity from behaving as the other system entities related to Account behave.

I have no theories and am aware of no evidence that might explain the change of behaviour, so am open to all suggestions from those with deep experience in this area of Dynamics!!

PS we have another instance of Dynamics running for which the automation is still working as expected for the custom entity, but unfortunately the client's customer, contact, quotation, product, price lists, inventory and custom entity data as well as the 25000 documents are not loaded into that instance.....

Thanks in advance for any ideas!

Regards,

Mike

*This post is locked for comments

  • Suggested answer
    RyanCPerry Profile Picture
    RyanCPerry 105 on 12 Mar 2020 at 22:40:58
    RE: Dynamics 365 SharePoint integration for custom entity - failing

    After receiving Kristie's comment that this is still an issue, I decided to do a write-up about this issue with document locations:

    Dynamics Sharepoint Integration uses Wrong Folder

    Hope this helps. 

    Ryan.

  • RyanCPerry Profile Picture
    RyanCPerry 105 on 12 Mar 2020 at 20:27:35
    RE: Dynamics 365 SharePoint integration for custom entity - failing

    Hi Kristie, happy to discuss / just sent you an add request.

    Our fields were likely addressing different business needs and the solution may well be quite different than yours.  There are also other options, such as building your own sharepoint integration, which can be done with Power Automate, or custom plugin dev. And of course, you may have some data to move.   Respond to the add / look me up on linkedin linkedin/.../ryanperrymba and let's chat.

  • Kristie L Profile Picture
    Kristie L 15 on 12 Mar 2020 at 20:10:53
    RE: Dynamics 365 SharePoint integration for custom entity - failing

    Hi Ryan, we are currently experiencing the same problem due to an other lookup referential relationship between Account and our Custom Entity.  Can you share what other ways you used to address the business needs for the look ups that were used?  It's 2020 and we are still experiencing this same issues, so it's evident that Microsoft has not resolved this problem.

  • Community Member Profile Picture
    Community Member Microsoft Employee on 15 Apr 2019 at 15:04:55
    RE: Dynamics 365 SharePoint integration for custom entity - failing

    Hello, we face the same issue now. Are there any news from Microsoft, when it will be fixed?

  • RyanCPerry Profile Picture
    RyanCPerry 105 on 26 Jul 2018 at 04:16:42
    RE: Dynamics 365 SharePoint integration for custom entity - failing

    HI Mitesh,  Removing the duplicate account lookups did resolve it.  We had to find other ways to address the other business need these lookups were used for.  IMO, this is an oversight on the part of MSFT. At the time they said they are aware of it and their development team would patch it up in a future release.

  • Community Member Profile Picture
    Community Member Microsoft Employee on 25 Jul 2018 at 16:36:18
    RE: Dynamics 365 SharePoint integration for custom entity - failing

    Hi Ryan

    Did you manage to fix this problem, I am having the same issue with contacts.

    Thanks

    Mitesh

  • RyanCPerry Profile Picture
    RyanCPerry 105 on 29 Jan 2018 at 17:27:15
    RE: Dynamics 365 SharePoint integration for custom entity - failing

    Hi Mike,

    Does your custom entity have multiple account lookup relationships?  We have run into the same issue.  The system was working fine at some point it began creating document locations outside of the account library.  We do have multiple account look ups: One is parental and the other two are referential, but suspect that perhaps the ambiguity of having three lookups is causing the issue even if one is designated as the parent.  

  • Verified answer
    Community Member Profile Picture
    Community Member Microsoft Employee on 01 Jul 2017 at 10:04:31
    RE: Dynamics 365 SharePoint integration for custom entity - failing

    Final Update:

    All is well, the File Not Found error was in fact genuine, since some folders had been moved in SharePoint without updating the document locations in Dynamics. Now to working out the best solution to relocating the documents that have been stored in non-preferred locations.

  • Community Member Profile Picture
    Community Member Microsoft Employee on 30 Jun 2017 at 13:35:05
    RE: Dynamics 365 SharePoint integration for custom entity - failing

    An update on this issue:

    The original problem has been resolved, but is now replaced by "File Not Found" (see below).

    The reason the integration was not creating folders under the account library was because a field of type "customer" had been added to the custom entity, in addition to the original, working correctly, lookup field from the custom entity to the account entity. This field, even though it was not actually used and even when it had the same displayed value as the original lookup field persuaded the integration that each custom entity record was not related to an account - in which case the software will, even when working correctly, create folders in the custom entity library rather than under an account record's folder in SharePoint (i.e. it was as if the lookup field had a null value).

    If you assume that the field of type customer has usurped the lookup field as the linkage between the related entities, then the fact that it does not work is unsurprising since a field of type customer would have intermediate structure to allow for customers that were contacts not accounts...

    The new problem is that when the software now tries to correctly create a custom entity folder under the account library, the dreaded "File Not Found" error is displayed (=> document location exists in Dynamics, but referenced SharePoint folder does not - we are supposed to be creating the folder at this point though).

    Stay tuned for the next episode or if you have relevant experience with this error message please reply.....!

    Regards,

    Mike

  • Community Member Profile Picture
    Community Member Microsoft Employee on 21 Jun 2017 at 08:00:27
    RE: Dynamics 365 SharePoint integration for custom entity - failing

    Hi Martijn,

    No the procedure was to create the folder for the custom entity record first - when automated this occurs simply by going to the associated document view for that record, it is created at that point, with no documents within.

    Then from that empty Dynamics list view you Open Location which takes you to the SharePoint folder that was just created.

    Unfortunately the client never noticed that these locations were in the incorrect library because the file copies which followed took 5-15+ minutes to complete so they would have been doing their everyday work between times, and only coming back to the copies when next available to copy the next lot of files (repeated 100 times over 10 days or so).

    The file copies were performed using the latest browser-dependent feature within SharePoint which allows uploading of a complete folder structure and all its subfolders and files. This is only supported by Chrome and Edge at present I believe, IE and Firefox do not support it (yet?), and you won't even see the option in those browsers.

    This folder structure and associated files were copied from the network into the "tail end" of the folder structure created by the Dynamics-SP integration - successfully in all cases, its just that the automated folders created by Dynamics were created in the wrong library after the first few had been successfully created under account record folders as previously described.

    Those first few are still there operating correctly, and the subsequent many are still operating useably but in the wrong place in SharePoint. You wouldn't know there was a problem unless you tried to access them through the account records - they aren't visible there, as was required.

    Cheers,

    Mike

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Tip: Become a User Group leader!

Join the ranks of valued community UG leaders

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,286 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,064 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans
Loading complete