You need to sign in to do that
Don't have an account?
Sai Harshitha Bandlamudi
How to reestablish lookup relationship in Target Org in S2S
I have a Object called "Object A" and it has a lookup with "object B" .
I have forwarded object A into Target Org using the trigger:
Similar trigger for
I have forwarded object A into Target Org using the trigger:
trigger SendObjectAToConnection on ObjectA(after insert,after update) { PartnerNetworkConnection conn = [select Id, ConnectionStatus, ConnectionName from PartnerNetworkConnection where ConnectionStatus = 'Accepted' and ConnectionName = 'ABC']; List<PartnerNetworkRecordConnection> recordConnectionToInsert = new List<PartnerNetworkRecordConnection> (); for (ObjectA acc : Trigger.new){ PartnerNetworkRecordConnection newrecord = new PartnerNetworkRecordConnection(); newrecord.ConnectionId = conn.Id; newrecord.LocalRecordId = acc.id; newrecord.SendClosedTasks = false; newrecord.SendOpenTasks = false; newrecord.SendEmails = false; recordConnectionToInsert.add(newrecord); } if (recordConnectionToInsert.size() > 0){ System.debug('>>> Sharing ' + recordConnectionToInsert.size() + ' records'); insert recordConnectionToInsert; } }Similar Trigger for Object B. When I publish both objects into the Target Org, I donot know how to recreate their lookup relatuionship.
Similar trigger for
[1] https://developer.salesforce.com/forums/?id=906F00000008xu0IAA