Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Migrating records and assigning them to "stub users"

Posted on by Microsoft Employee

Hi!

I am migrating data from CRM on premise to Dynamics 365 platform. Because I want to preserve historical data, we created "stub users" in Dynamics 365, which gets assigned salesperson security role by default. security role has been changed to allow "Override Created on or Created by for Records during Data Import".

For data migration I am using Kingswaysoft SSIS components. 

Prior to June's update of CRM, there was no problems, and you could easily replace creation user with stub user and also assign ownership to it.

Now, when I am trying to do this, I am getting error message from CRM's API:

: CRM service call returned an error:
The user with SystemUserId=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx in OrganizationContext=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
is not licensed, and its SystemUserAccessMode is not either of (NonInteractive, SetupUser) (Error Code: -2147167669, Detail Message:
The user with SystemUserId=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx in OrganizationContext=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx is not licensed,
and its SystemUserAccessMode is not either of (NonInteractive, SetupUser))System.ServiceModel.FaultException<KingswaySoft.DynamicsCrmServices.Soap2011.OrganizationService.OrganizationServiceFault>

Has anyone had the same experience and found a solution? Many thanks!

Slavko

*This post is locked for comments

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Migrating records and assigning them to "stub users"

    So, per Andrew suggestion, I tested load without CreatedOn field, but tried to set Owner with the same stub user. This is working fine, stub user can be record owner.

    But this result is not depicting real state after migration of source data and this is important for my client.

    My conclusion is, that MS produced a bug with one of latest releases, most likely with Junes 2018 release, because I am experiencing this issue from this time on.

    So this security feature is not working on data import:
    override_5F00_createdby.png

    Created on is overriden after load, but not created by. I didn't test load with CRM import tool, but I do not like to use it for importing massive number of records.

    Regards!
    Slavko

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Migrating records and assigning them to "stub users"

    Hi @Andrew!

    Thanks for your answer. I had opened ticket on MS support and on one of environment, where we will go live in 2 weeks, they managed to solve the isue and I was able to set createdby field and confirmed, that it is working (on sandbox). I tested yesterday on future live environment, and it is not working there. Then I did test again on sandbox, and it is not working there too. So their solution was only temporary.

    Because I have currently more migrations in place, it looks like I have to open ticket for every client, 2 times, as I have to do this for both environment instances (sandbox and production). What I hate about this is, that everytime I open ticket, I get another support guy, who do not know the solution and we are goint trough procedure, as it is first time :-/

    I will open tickets now :)...sorry guys, I will occupy whole support team next week :-D

    Kind regards!

    Slavko

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Migrating records and assigning them to "stub users"

    Hi @Andrew!

    Thanks for your answer. I had opened ticket on MS support and on one of environment, where we will go live in 2 weeks, they managed to solve the isue and I was able to set createdby field and confirmed, that it is working (on sandbox). I tested yesterday on future live environment, and it is not working there. Then I did test again on sandbox, and it is not working there too. So their solution was only temporary. 

    Because I have currently more migrations in place, it looks like I have to open ticket for every client, 2 times, as I have to do this for both environment instances (sandbox and production). What I hate about this is, that everytime I open ticket, I get another support guy, who do not know the solution and we are goint trough procedure, as it is first time :-/

    I will open tickets now :)...sorry guys, I will occupy whole support team next week :-D

    Kind regards!

    Slavko

  • Suggested answer
    a33ik Profile Picture
    a33ik 84,323 Most Valuable Professional on at
    RE: Migrating records and assigning them to "stub users"

    Hello,

    I'm afraid you will have to leave the idea to populate Created By field. I do the migration now and I have to go the same way.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Migrating records and assigning them to "stub users"

    This is stub user. It is created using import directly to Dynamics 365. It has assigned security role by default and you cannot change it. You can see description what stub user is at the bottom of mentioned article. I can assign record to this user over GUI. The limitation is only on API and I suspect that MS development produced this error message with June 2018 update, because prior to this update I didn't have this kind of difficulties on migration.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Migrating records and assigning them to "stub users"

    With further analysis of the issue I tried to assign contact record to the same stub user in CRM. This works fine, without error message. So, the issue is only on API.

    This is from developers documentation on MS sites: 

    Name: UserNotAssignedLicense

    Hex: 8004D24B

    Number: -2147167669

    The user has not been assigned any License

    Because user is former employee, it will not get license, because there is no need. This is huge limitation on migrations, I can conclude, because we want to preserve historical data as it is.

  • Mahadeo Matre Profile Picture
    Mahadeo Matre 17,021 on at
    RE: Migrating records and assigning them to "stub users"

    Hi..

    I think as per error message, you need to assign license to user and need to change access mode.

    You can do assign license and access mode from user record

    here is more detailed information

    docs.microsoft.com/.../create-users-assign-online-security-roles

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans