Open Cases By User By Status (chart)

SugarCRM

 

SugarCRM is a cloud CRM from the SugarCRM software company, that includes sales force automation, marketing campaigns, customer support, collaboration, reporting, etc. features.

Open Cases By User By Status (chart)

Query Text

SELECT U."user_name" 'User Name',
    SUM(case when C."Status" = 'New' then 1 else 0 end) 'New Cases',
    SUM(case when C."Status" = 'Assigned' then 1 else 0 end) 'Assigned Cases',
    SUM(case when C."Status" = 'Pending Input' then 1 else 0 end) 'Pending Input Cases'
  FROM "cases" C, "Users" U
  WHERE C."Status" IN ('New','Assigned','Pending Input') and
        C."assigned_user_id" =U."Id"
  GROUP BY U."user_name"
  order by U."user_name"
  

Open Query