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

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

How to force two entities to synch a lookup field

(0) ShareShare
ReportReport
Posted on by

I have two entities - Case and Sales Order (custom)

We do a lookup from Sales Order to Case, and also from Case to same Sales Order

It seems redundant and inefficient to do this twice - I'm thinking there has to be a better way

ie:

  • if user looks up a Case from the Sales Order, then the Case would update it's link to the Sales Order after the Sales Order is updated with a link to the Case
    • and vice-versa
  • if user looks up a Sales Order from the Case, then the Sales Order would update it's link to the Case after the Case is updated with a link to the Sales Order

I would assume that once I have done a lookup from either the Case or Sales Order, I already have created the link in the related record but I haven't found a way to make it display in the second record, short of doing this same lookup from the reverse direction.

Anyone have ideas on a more efficient way to accomplish this?

Thank you.

*This post is locked for comments

I have the same question (0)
  • Verified answer
    PS Profile Picture
    23,577 on at
    RE: How to force two entities to synch a lookup field

    Create a workflow on sales order

    If case contains data

    Update case>> sales order equal sales order

    Create a workflow on case

    If sales order contains data

    Update sales order >>case equals case

  • Daniel at VNS Profile Picture
    on at
    RE: How to force two entities to synch a lookup field

    Thank you Prashant.  This is what i was thinking initially but I was then wondering if there wasn't some OOB functionality to handle this and I might be making it overly-complicated.  

    I also started to wonder if we would not also want to add a bi-directional relationship mapping so that new Sales Orders or Cases created would pre-populate with these 2 fields.  Then I realized i already had done that, and had both an N:1 and 1:N from Sales Order to Case.

    The N:1 allows for multiple Sales Orders to link to a single Case (the exception rather than rule but it happens).

    The 1:N allows for a single Sales Order to link to a Case with a lookup from the Case or Sales Order.

    But that still doesn't solve the synch issue if one or the other is entered first.  So we're back to WF, which did the trick.  

    THank you as always for your excellent input.  I need to start reading your blog.

  • Suggested answer
    PS Profile Picture
    23,577 on at
    RE: How to force two entities to synch a lookup field

    Hi Daniel,

    As you already know that you have created two relationships in the system:

    Order Lookup on case form is 1(Case): N(Order)

    Case Lookup on order form is 1(order): N(case)

    which makes the relationship between order & case as N:N

    And N:N cannot be auto-populated on lookups, so, how you can see it?

    You can create order subgrid on Case and set it to related order/record only

    You can create case subgrid on order and set it to related case/record only

    So the system does have information about it, it just cant be auto-populated on a lookup.

    And workflow was the easiest work around I thought of :)

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
Community Member Profile Picture

Community Member 2

#1
UllrSki Profile Picture

UllrSki 2

#1
HR-09070029-0 Profile Picture

HR-09070029-0 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans