Loading

How to retrieve Detail objects from Master-Detail relationships in MuleSoft Composer

Publiseringsdato: Oct 13, 2022
Beskrivelse

When building a sync in MuleSoft Composer for a detail object which is involved in a Master-Detail relationship, the Object Field doesn't populate.

 

Løsning
Master-Detail has to be manually linked using multiple get records steps and using Detail's Record ID and Master's Detail C value (not Record ID) which are fields that are exposed on the object.

As an example, if the Master-Detail relationship is used in two custom objects called Property and Favorite, creating a flow to achieve this will have the following steps:
  1. A trigger (it can be a scheduler)
  2. A Get records action in SF that gets the object type Property.
  3. A For Each item which input is the List of Property that the previous step outputs.
  4. Inside the For Each, place a Get records action in SF that gets the object type Favorite with the condition that the Favorite's field "Property C" must be equal to the String value "Record ID" (from step 2).
Step 1Step 2Step 3 and 4
Knowledge-artikkelnummer

000393172

 
Laster
Salesforce Help | Article