Loading

A report dynamically filtered with the user lookup field does not show dynamic results

Udgivelsesdato: Oct 13, 2022
Beskrivelse
The User lookup field will not work when used as a dynamic report filter. What users will see are static instead of dynamic results. 

To work around this, create a custom field that will look up the current running user, then create a formula checkbox field which determines if the user viewing the report is the running user. 

The sample formula below uses the Account object as an example with Consultant__c as the substitute for the User lookup field. 

Please take into consideration the scope of support Salesforce offers with regards to formulas. You may review Scope of support for formulas.
Løsning

A formula checkbox field wherein the syntax would be: 

"$User.Id = Consultant__c"

Where User.Id is the syntax for current running user. 


To create the field, follow these steps:  
 
1. Click the gear icon and select Setup
2. Click on Object Manager
3. Look for the Account object and select Fields & Relationships
4. Select New
5. Choose Formula as the field Type
6. Choose Checkbox as the return type
7. Enter the syntax $User.Id = Consultant__c
8. Click Save

On your report, make this field as one of your filters and set it to True. Remember that the checkbox field is to determine if the running user is the same as the Consultant ID field. 
 
Vidensartikelnummer

000380280

 
Indlæser
Salesforce Help | Article