You need to sign in to do that
Don't have an account?
Dorel4
Cross object formulas
I am created a formula field called "List Agent" (see below). I wpuld like to take the Listing Agent ID LR Source field's information and look up in the Custom Object "Agent" to see if there is an Agent ID that matches, If it does, I would like the Agent Name to be returned. I can not get the formula to use the Listing Agent ID LR Source to search in the Agent Object. Please help. If this is not possible with a formula please advise my options. Thank you
IF( Listing_Agent_ID_LR_Source__c = Agent__r.Agent_ID__c , Agent__r.Name , NULL)
IF( Listing_Agent_ID_LR_Source__c = Agent__r.Agent_ID__c , Agent__r.Name , NULL)
1. Write before insert trigger on Listing Agent ID LR Source field object
2. Using soql query get the Agent information based on the Listing Agent ID LR Source field's information
3. Then assign the matching value to the custom field
The above is writen with the assumptions of the field and object name, you need to replace the objectname and field names as per your org else this trigger won't get saved in your org.
I suggest you to take a look into the salesforce Trailhead which helps you to get programticaly.https://developer.salesforce.com/trailhead