Date Filter in Salesforce Report

Using the date filter we can create a more structured and understandable report, it helps us to analyze and visualize data.

In this Salesforce tutorial, we will learn about the Date filter, relative date filters, and how to group reports by dates in the Salesforce Report. Additionally, we will see how to apply the date filter in Salesforce Lightning and Salesforce Classic.

Date Filter in Salesforce

What is the date filter in the Salesforce report?

The date filter in the Salesforce report only supports the custom and standard date fields. Using the date filter we can create a more structured and understandable report, it helps us to analyze and visualize data.

Examples:

  • If we have a report, in that report thousands of records are there and we want to display those records month-wise means not including the date only month and records created by that month it will display that month in a group.
  • This enables to the user narrow down our data and makes it more straightforward to analyze data. It makes our task easier.

What is the relative date filter in the Salesforce report?

The relative date filter allows us to filter on a date field, using informal wording-inspired syntax. For example, instead of “Close date greater than 1 Jan. 2024”, we can simply write “Close date equals this year”.

How to group reports by dates in Salesforce?

See also  How to Create Opportunities by Month Report in Salesforce

In Salesforce, we have a feature to group the records by date, month, and year termed a grouping.

In grouping by date, we organize a group of data with date-related criteria. For example, group opportunities by Close Date to see closed opportunities or group cases by product to see the number of cases for each product.

How to apply the date filter in Salesforce Lightning

In the following steps, we will see how to apply relative date and how to group reports by dates.

1. Go to “App Launcher” -> Search “Reports” -> Click on Reports.

Report Filter in Salesforce Lightning

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

Create new date Filter Report in Salesforce

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.

Date Filter in Salesforce Report

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

date Filter in Salesforce

5. Now we want to apply the “Relative date filter“, for that click on the Filter option -> Choose field “Close Date” -> Select operator “equals“.

6. In the relative date field you can type values like YESTERDAY, TODAY, TOMORROW, NEXT 30 DAYS, here I have chosen “LAST YEAR” -> Click on Apply.

relative date filter in salesforce lightning report

7. After that you will see the close date of the report displayed by sorting to last year, If the present year is 2024 then the last year will be 2023.

Apply relative date filter in salesforce report

8. Now we will see Group by filter, for that choose Group rows, here I have chosen “Close Date“. That means I will make a group of close-date fields.

Apply group date filter in salesforce

9. To apply the “Group Date By” use the following steps.

  • Choose which type of date you want to make a group. Here I have selected “Close Date“.
  • Click on the dropdown arrow -> you will see the “Group Date By” option.
  • Then you need to select duration to group the records. I have selected “Calendar Year“.
Apply group date filter in salesforce report

9. Now you can see after Grouping records Yearly how it displayed.

Apply group date filter in salesforce report result

This is how we can apply relative dates and how to group reports by dates.

See also  How to Create Row Level Formula in Salesforce Report

How to apply the date filter in Salesforce Classic.

In the following steps, we will see how to apply relative date and how to group reports by dates.

1. Go to All Tabs -> You will see the “Reports” tab -> Click on the Reports tab.

Date Filter Report in Salesforce Classic

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

Create Date Filter Report in Salesforce Classic

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

Date Filter in Salesforce Classic

4. After that click on the Filter button to add the Date Filter conditions.

date filter in salesforce report Classic

5. Now to add a condition you need a Date Field, then we can compare the date as per our requirement and we can filter the report.

Here I want the Created Date equal to 15/07/2022, then click on the Filter option -> Choose field “Created Date” -> Select operator “equals” -> Then choose the date “15/07/2022” -> Click on OK button.

After that, you can see all records will filtered by the Created Date field.

Report using Date Filter in Salesforce

This is how we can use the date filter in Salesforce Classic.

Conclusion

Now I hope you have got an idea about what is date report, in that we have seen relative date reports then group by dates filter. additionally, we have seen how to use the date filter in Salesforce Lightning and Salesforce Classic.

You may like to read