web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Copy associated records on a duplicated record

(0) ShareShare
ReportReport
Posted on by 270

Hi Guys

Please help. I have created a workflow that create duplicate of a record on demand. So on the original record I can see see associated records on the the subgrid, however on the duplicated record I cannot get those values.

I assumed since the record Id and name that I I used in both records are the same then associated data will show.

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Alex Fun Wei Jie Profile Picture
    33,628 on at

    Hi,,

    Although all the values for the duplicate record is same with the original record, but the record Id is not same.  

    Each records is unique.

  • TomSmelser Profile Picture
    1,570 on at

    Hi,

    To add to what Wei said... when creating a duplicate record that record has it's own unique guid (key).

    The related records in the grid would also have to be associated with the new record.

    Think of an order. That has order details like name, address etc. Then it may also have related products or line items.

    When you create a duplicate you will also have to create matching line items. 

    In a workflow doing a simple record create to duplicate the primary record is easy.

    Getting the related records will likely have to be done with a custom workflow activity.

    Here are some links that may help.

    Good Luck! Please click verified if this helped you solve your problem.

    https://www.inogic.com/product/productivity-pack/click-2-clone-microsoft-dynamics-crm-records

    https://www.youtube.com/watch?v=Iti9nfgomDg&feature=youtu.be

  • Suggested answer
    gdas Profile Picture
    50,091 Moderator on at

    Hi Samarando ,

    Your question is bit tricky :) , its hard to understand when I read first line , but second line its clear for me .

    So when you create duplicate record , that means that it will create another record being copying of same mentioned fields value except GUID or unique id  in the workflow. Which means a record name and other fields can easily be same in your duplicate record  but its does not mean that the record which you are copied from automatically create the relationship which are there in  existing record.

    As you  can not create same id , or GUID or unique ID in same entity because unique constraint of database . So you have to create relationship with  of sub grid record with your new record separately with new GUID or unique id of new record  . It will not automatically create.

    Hope this helps.

  • Suggested answer
    Mahendar Pal Profile Picture
    45,095 on at

    Hello,

    While cloning record you need to make sure you are also cloning related entity records and setting association with the new record you just created.

    For exam let say your current record A has association with child entity B and C, and now when you making clone of record A, you need to also make clone of record B and C, and further need to associate these cloned records.

    Hope it will help

  • Suggested answer
    Aric Levin - MVP Profile Picture
    30,190 Moderator on at

    Hi Samrando,

    There are various options for cloning records with related entities out there, which you can implement within your solution.

    I have developed something similar some time ago, but it might need some tweaking for your exact requirements.

    Take a look at:

    github.com/.../XrmClone

    Solution and Source code included, so you can modify it as you need...

    Hope this helps.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans