Showing results for 
Search instead for 
Did you mean: 

Prefilter SFM Search

Fry Chef
Fry Chef

Prefilter SFM Search



We are currently facing a business issue:  My client is interested in the SFM search functionnality but needs to prefilter it dynamically.


The SFM Search is currently offering static filters for each SFM Search which works juste fine. I am looking for a way to define dynamic filter (example: Filter on Account Id on Locations search and calling the SFM Search on the Account screen). Is there some doc or hint to set some parameters on the VF Page SFM Search ?


Thanks for your help




Re: Prefilter SFM Search

Hi Nicolas,

I'm not sure there is anyway to adjust for this.  There are some settings as noted below that can be filtered upon, that may help:

Keyword Search

Keyword search is executed to retrieve up to the maximum configured number of matching records from the lookup object. The match operator can be one of Contains, Starts With, Ends With, and Exact Match, with Contains being the default operator.

The default operator is determined by the value of the global configuration setting GBL017, the Default search operator (module Common, submodule Global Settings). This setting applies to SFM Search also.

Search fields configured in the associated lookup configuration or the Name field are searched for the specified match with the keyword entered.

The search applies basic filters if any configure, with no indication to the user, and no option to the user to turn it off. For example, the technician lookup above can have a basic filter to return only Active technicians.

Context Filter

Your administrator can configure lookup contexts based on the value of another field displayed in the page layout. This context field can be in the same object or in the header object (for child objects only). For example, your administrator can set up Account as the context for the Contact lookup field.

The context filter, if any is defined for a lookup field, adds an additional filter (to the keyword search) based on an exact match between the context field value and the matching field value in the lookup object.

For example, if an Account is set up as a controlling/context for Contact lookup and you have selected ABC Inc. in the account field, the contact result set will display only those contacts that are linked to the account ABC Inc. If you entered a keyword in the lookup field, the result set will display only those contacts whose name contains your search query and whose account is ABC Inc.

Depending upon the setup, you may be allowed to override this behavior and select to search all contacts irrespective of the account, but matching the keyword entered if any. See below the optional context filter for Technician lookup field based on Primary Territory.

Advanced Filters

Your administrator can set up one or more advanced filters to create filter criteria based on related object(s). For example, your administrator can set up an advanced filter for technician lookup field based on Expertise object’s (Skill) Availability End Date not being a past date in order to limit the technician records to those technicians with valid skills only.

Following are the steps to use Advanced Filters functionality in SFM Delivery:

  1. Enter text in the lookup field if required and launch the lookup search window.
  2. Click the Advanced Filters icon (next to the lookup icon, top right) to display the list of applicable advanced filters.
  3. You will be able to check / uncheck the checkbox for each advanced filter to apply / not apply individual filters for advanced filters that allow override.

Note: Advanced Filters configured with Default On checked will get applied by default when a lookup search is done based on keyword.

The standard lookup configuration for a Product object has an advanced filter to return only parts that are available in the logged in technician’s user trunk. This filter is off by default, but can be turned on by the end user.