Skip to main content

Notifications

Customer Service forum

Excel import - Account Survey duplicate

Posted on by 180

Hello,

I have account survey data that i am storing in a custom entity that has 1:M relationship with account. In the account survey custom entity, i have created a lookup to account name, that pulls the parent account name. I should only store survey for those account records that exists in CRM. If i import the survey data using excel import, the second time onward the import creates duplicate records in account survey custom entity, i would have to make the second import to update the existing account survey record rather than inserting a new one. any idea? Actually, i have to make the account survey custom entity as just 1 to 1 rather than 1 to M with parent account record. Please share your thoughts. Thanks!

Categories:
  • Suggested answer
    LeoAlt Profile Picture
    LeoAlt 16,329 on at
    RE: Excel import - Account Survey duplicate

    Hi partner,

    There are three ways for you to do this.

    1. Use Duplicate Detection Rules

        Dynamics 365 has an OOB function to check the duplicate data named "Duplicate Detection Rules". Go to Settings->Data Management->Duplicate Detection Rules and create a new record.

    4011.community18.png

    4011.community18.png

    (In my case, I have a look up field related to entityB on entity A, so I add a duplicate rule on the "B" field and then I tried to import a data with a existing B record to entity A, and the record has updated succesfully instead of creating a new one)

    Save and publish it and then you could try to import your data now.

    2. Develop a plug-in with C# at the pre-create event of your custom entity and judge if the account has existed in your custom entity.

    docs.microsoft.com/.../run-duplicate-detection

    3. Use Dynamics 365 web api to control the duplicate rules.

    docs.microsoft.com/.../manage-duplicate-detection-create-update

    Hope it helps.

    Best Regards,

    Leo

  • Suggested answer
    LuHao Profile Picture
    LuHao 40,872 on at
    RE: Excel import - Account Survey duplicate

    Hi partner,

    When importing data via the Import Data Wizard, you should need to choose whether to allow duplicate records.

    4747.1.PNG

    It defaults to No, so no duplicate data is imported.

    Please refer to the following blogs about importing data:

    https://community.dynamics.com/crm/b/friyanksblog/archive/2018/03/15/setting-gt-data-management-gt-data-maps-data-import-template-for-data-import-sample-data

    https://crmbook.powerobjects.com/basics/data-management-in-microsoft-dynamics-crm/importing-data-in-microsoft-dynamics-crm/the-data-import-wizard-in-dynamics-crm/

    https://www.encorebusiness.com/blog/how-to-use-import-in-dynamics-365-customer-engagement/

    ------------------------------------------------

    In addition, to achieve a 1:1 relationship between account survey custom entity and parent account, you could create duplicate detection rules for the parent account name field of the account survey.

    In this case, it is guaranteed that the account survey has no duplicate parent accounts and has the same effect as the 1:1 relationship.

    Please refer to the following bloggers about duplicate detection rules:

    https://docs.microsoft.com/en-us/dynamics365/customer-engagement/admin/set-up-duplicate-detection-rules-keep-data-clean

    https://rocketcrm.co.uk/dynamics-365-duplicate-detection-rules/

    https://www.advantage.co.uk/blog/tips-tricks/how-to-create-and-use-duplicate-detection-rules-in-dynamics-365/

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

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans