mysql - SQL SUM only return values >=1 -
i have simple query want return values
select advisor advisor, sum(`outcome` '%tps_approved%') approved shift_report `team`!=6 , date>20150720 , date<20150728 group `advisor` order `advisor`
i want return advisor , approved count if count >=1
would want ?
select advisor advisor, count(*) approved shift_report `team`!=6 , date>20150720 , date<20150728 , `outcome` '%tps_approved%' group `advisor` order `advisor`
Comments
Post a Comment