Using SQL Server, I am simply trying to add criteria for the second line, so the report counts the number of instances where caseType = 'WC' and openDate <= '2015-04-25'. I am struggling with adding the later criteria, it keeps throwing an error.
sum(case caseType when 'WC' then 1 else 0 end) 'Cases prior to Commercial'
sum(case caseType when 'WCP' then 1 else 0 end) 'Leads'
group by caseType
This code works. Again, I just need to add the date part outlined on my above explanation.
Thanks so much,