Skip to main content

How to Find Max Recently Closed Activity on Opportunity?

Updated over 5 months ago

Please follow the steps included below for creating a rollup to find max recently closed activity on the opportunity.

Note: Salesforce does not support any aggregate operations on the 'ActivityDate' field, but we have a workaround here to fulfill the requirement using PWR Rollups please follow the below steps for the solution

To achieve this requirement, the user needs to create a custom formula field.

Create a formula field on the Task/Activity Object with return type Date, Formula = ActivityDate

  1. Open PWR Rollups application

  2. Create a new roll-up and give the appropriate name and description

  3. Select the source object as Task and the destination object as Opportunity, and click next

  4. Select the rollup type as Maximum and for the Source field select the formula field which you have recently created

  5. Select the destination field where you want to show the result (It should be the Date field)

  6. Now, click on the 'Add Condition' button

  7. Please refer to the screenshot below for the filter specifications

  8. Check the checkbox to make rollup active then click on save

Now you have successfully created the rollup to fulfill your requirement.

Did this answer your question?