We use contains as an operator that is used for the filter reports as per our requirements. When we want all records that hold a particular value, the value can be a string or number. That time, we can use a contains filter.
In this tutorial, we will learn about the contains filter report, what is the contains filter, its Advantages and Disadvantages, and how to apply this filter in Salesforce. Additionally, we will see how to use the contains filter report in Salesforce Lightning and Salesforce Classic.
Contains Filter in Salesforce
What is the contains filter in Salesforce?
In the Salesforce report, we use contains as an operator that is used for the filter reports as per our requirements. When we want all records that hold a particular value, the value can be a string or number. That time, we can use a contains filter.
For example, in the opportunity object, we want all records that contain the “Communications” word, and we want to fetch all records which has the Communications word. That time, we can apply the contains filter on the report.
Advantages of the contains Filter –
- If we have a report in that report, thousands of records are there, and we want to find only those records that contain a particular value.
- This enables the user to narrow down our data and makes it more straightforward to analyze data. It makes our task easier.
Disadvantages of the contains Filter –
- It is not Case Sensitive, which means when you try to search “Salesforce” word and in that field multiple words are there like Salesforce Classic, Salesforce Lightning all records will display.
- If you try to search short String, Eg. “Com” it will display all records that contain Com like, Computer, commodity, company, etc. That is a drawback of contains filter.
How to Apply Contains Filter Report in Salesforce Lightning
Now, we will see how to apply a contain filter with an example.
1. Go to “App Launcher” -> Search “Reports” -> Click on Reports.

2. To create a new report, click the “New Report” button.

3. Go to All category -> to select a report type, Search “Opportunities“, you can search on which object you want to create a report. -> Select Opportunities.

4. You can see all records will displayed in the report.

5. Here, we want only those records in which Opportunity Name Contains “Edge“. To apply the contains filter -> Click on the Filter option -> Select the field “Opportunity Name“.
6. Select the Operator Contains -> Enter the string which you want to search here I have entered “edge“. -> Click the Apply button.
- Locked – Using this option, we can lock this filter, which means no one can edit this record on the report run page.

7. After applying the contains filter, only those records will display who contain the “edge” value.

This is how we can apply the contains report filter in Salesforce Lightning.
How to Apply Contains Filter Report in Salesforce Classic
Now we will see the steps, of how to apply the contains filter with different examples.
1. Go to All Tabs -> You will see the “Reports” tab -> Click on the Reports tab.

2. Then click on the “New Reports” button to create a new report.

3. Select the Object, here I have selected “Leads” Object -> Click on the Create button.

4. Here, you can see when I have created a report of Leads details and all records coming up.

5. Here we want only those records in which the Company/Account field Contains “Com“. To apply the contains filter -> Click on the Filter click on Add option -> Select the field “Company/Account“.
6. Select the Contains Operator -> Enter the string which you want to search here I have entered “Com“. -> Click the OK button.

6. After applying the contains filter, you can see only those records that contain the “Com” value.
You can see some differences here, We have searched for “Com” and as a result, we have gotten Telecom, Com, Computer, and Telecommunications which means that the value we searched can start with, end with, or present in between words.

This is how we can apply a contains filter on a report in Salesforce Classic.
Conclusion
I hope in this tutorial you have got an idea about what is a contains filter in the report with examples, what is the advantages and disadvantages of a contains filter, and how to apply a contains filter report in Salesforce Lightning and Salesforce Classic with different examples.
You may like to read:
- How to Use Lookup Field with Filter in Salesforce
- How to use OR Filter in Salesforce Report
- Date Filter in Salesforce Report
- How to Create Lookup Filter in Salesforce
- How To Group Report By Year In Salesforce
I am Bijay Kumar, the founder of SalesforceFAQs.com. Having over 10 years of experience working in salesforce technologies for clients across the world (Canada, Australia, United States, United Kingdom, New Zealand, etc.). I am a certified salesforce administrator and expert with experience in developing salesforce applications and projects. My goal is to make it easy for people to learn and use salesforce technologies by providing simple and easy-to-understand solutions. Check out the complete profile on About us.