One of my custom objects have a relationship with User object. I need to pull SAML Federation ID (Field Name: FederationIdentifier) of User object into a formula field in the custom object through this relationship, but it is not available in the Insert Field pick-list. Screenshot below.
First create a shadow TextArea (long) (len =512) Federation Id field on User -
- Use Process Builder to set FederationId__c from Saml Federation Id in an update action that executes unconditionally. Unfortunately, SAML Federation ID isn't available to Workflow Field Updates - only Process Builder
- Use a before insert/update trigger on User to do the same as #1
Use the shadow field in your cross object formula
SAML Federation ID in Reports
This is not an answer to the question I asked. But in case you reached here, requiring SAML Federation ID of a related user only in a report, you do not have to create a new Formula Field. Instead, you could simply add it to your report type via a lookup. Instructions and screenshot below:
- Go to Setup > Build > Create > Report Types.
- Drill down on the Report Type that belongs to the object, in which you need to fetch the SAML Federation Identifier of related user.
- Click Edit Layout.
- On the right pane, choose your object in the View selector.
- Click the link that reads Add fields related via lookup >>.
- Drill down on your user relationship field (in my case, it is "Current User") and choose SAML Federation ID. Click Ok.
- Save the Report Type.
You will now find SAML Federation ID in the list of fields available for you report. Cheers!