How to Apply Server-side Filters in XRL
Explore how to create server-side filters for displaying relevant records in XRL Data Views
Introduction
Orenda Grids - Extended Related Lists (or XRL) allows you to control the data fetched in data views from the database with server-side filters. By applying an intuitive Server-side filter, any user can control the records displayed in the data set of the Salesforce views at the server level with an easy-to-use SOQL query builder, and create multiple views with different data sets. The query builder also supports 5-level look-up fields to get access to a granular view of the data set, which is persistent and available in subsequent sessions.
Limitations in Salesforce Views for Filtering Data
In Salesforce data views, filtering is very restricted. Take example of Related Lists where filters are limited such that-
- Filters are applicable to only those fields which are configured to display in the Related List. This means, if a field is not visible in the Related List, the user can't filter the data based on that field.
- Filtering of records can be done only after configuring the Related List when we use Related List Single. Thus the Related List contains a lot of data that is not particularly useful for the user.
- Data filtering is not persistent, and filtered data is available only for the current session.
- In Dynamic Related List server-side filtering is available to define a condition based on which data is fetched in the Related List view. But Dynamic Related List can be configured by only admin or admin-like users. Moreover, Dynamic Related Lists display only 30 records which is gives very limited data in case of heavy data sets and is not useful for end users.
In XRL, you have ability to define the data views such as Related List view with specific server-side filters to multiple fields and the logical conditions can be modified using AND/OR clause as necessary.
By applying server-side filters, you get rid of excess records in the Related List, which makes it easy to browse through Related List and search for relevant information.
In this article, you will learn how to apply server-side filters to different fields and control the records displayed in the Related List view.
Which type of user can use this functionality?
Orenda Grids XRL Power users and Standard users can use server-side filters to configure a Related List view with a specific data set that is retrieved in the view from the database. Make sure, you are added as licensed user and have required permission set to access and work on XRL.
Prerequisite: Make sure that you log in to your Salesforce account, install, and configure Orenda Grids XRL. Refer to the links below for more detailed instructions. |
Procedure
Once you have configured the Orenda Grids XRL, you can apply server-side filters to ensure that only particular records are displayed in the data view according to the use case. Let's understand how this is done in Orenda Grids XRL.
Apply Conditions
As the name suggests, these records are fetched directly from the database depending upon the SOQL query that a user can build through an easy-to-use query builder.
We will work with Cases XRL example to walk you through the steps to apply server-side filters using XRL.
Step 1: On the XRL Related List View, click on the gear icon at the extreme right and select Configure.
Step 2: On the Configuration Wizard, click on the Apply Conditions in the Field Selection tab.
Step 3: Select any field from the Available Fields from Case on the left, to which you need to apply a server-side filter.
Filtering Criteria
Step 4: Filter Criteria
Choose the appropriate filtering criteria. A variety of operations are available and are displayed depending on the type of Available fields such as "contains", "equals", "is not empty," and more.
- Is equal: This filter displays the records with data that exactly matches the filter value
- Is not equal: This filter displays the records with data that does not exactly match the filter value
- Begins with: This filter displays the records with data that begins with the specified value
- Does not begin with: This filter displays the records with data that does not begin with the specified filter value
- Ends with: This filter displays the records with data that ends with the filter value
- Does not end with: This filter displays the records with data that does not end with the filter value
- Contains: This filter displays the records with data that contains the exact filter value
- Does not contain: This filter displays the records with data that does not contain the exact filter value
- Greater than: This filter displays the records with a value greater than the filter value
- Greater or equal: This filter displays the records with a value greater than or equal to the filter value
- Less than: This filter displays the records with a value lesser than the filter value
- Less or equal: This filter displays the records with a value less than or equal to the filter value
- Range: This filter displays the records with a value within a specified range
- Is empty: This filter displays the records which contain no data in the specific field and leaves out the records which have any value corresponding to the field.
- Is not empty: This filter displays only those records which contain any value for the mentioned field, leaving out all the records where the corresponding field is empty.
Applied Conditions
Step 5: Applied Conditions
- Once you choose an appropriate filter option and click on Add Condition it is added to the list of Applied Conditions. These conditions will be applied when loading the grid.
- If you want to Edit any of the Applied Conditions, under the Actions field, click on the Edit button.
- If you want to Delete any of the Applied Conditions, under the Actions field, click on the Delete button.
Conditional Filtering Pattern
Step 6: Condition Filtering Pattern
Construct different logical connections among conditions using parenthesis and the words ‘AND ‘OR’. By modifying the parentheses' or logical operators' order, you can adjust the Boolean logic as necessary.
By default, multiple filters are applied for work on AND logic.
Step 7: You can apply filters to any other field as necessary, even to the fields not configured to display in the Related List view. Click Save to modify the current Related List view. In case, you need to have a separate view, click “Save As”.
Results
With the above procedure, you will be able to see a Related List view with XRL which has only relevant records to get your task done.
You can also enable dynamic server-side filters in ad hoc data views. Go through the article on enabling ad hoc server-side filters to learn more.
Check out our article on Client-side filters further and learn how server-side and client-side filters aid you in quickly finding the correct data at the right time.