function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Brandon (Penrod)Brandon (Penrod) 

Reports: Summarize by Date

Question: We have a bunch of Opportunities grouped by accounts, how would we summarize by date (min/max) so that it only shows the first/last Opportunity per Account?
Ankit Gupta@ DeveloperAnkit Gupta@ Developer

Try the below SOQL query as reference:

select max(createddate),min(createddate) from opportunity group by accountid

Ankit Gupta