Activity Forums Salesforce® Discussions how to count open cases against owner id by map in Salesforce?

  • how to count open cases against owner id by map in Salesforce?

    Posted by yash ghatge on December 31, 2018 at 8:13 am

    list<AggregateResult> result = ([select ownerid,count(id)total from case where isclosed = false group by ownerid]);

    map<id,integer> mapresult = new map<id,integer>

    For (AggregateResult aggresult : result)

    {

    mapresult.put(aggresult.get(aggresult.ownerd),aggresult.get(total) )

    • This discussion was modified 5 years, 3 months ago by  yash ghatge.
    • This discussion was modified 5 years, 2 months ago by  Forcetalks.
    • This discussion was modified 5 years, 2 months ago by  Forcetalks.
    Jade replied 5 years, 2 months ago 2 Members · 1 Reply
  • 1 Reply
  • Jade

    Member
    January 30, 2019 at 10:26 am

    You can also explore report features here. Summary report on case to display only open cases and then group it by owner names.

     

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos

Salesforce Admin Certification 2020 Questions Explained with References - Part II

Video in

How to prepare and pass Salesforce Admin Certification with Practice Exam Questions 2020 practice questions and answers for the Salesforce Administration Salesforce Certified Admin Exam Questions Salesforce Administrator Certification Exam…