select mngrs.manager_id from
(select mn.chief_id, cl.manager_id, count(1) cn
from claim cl
inner join manager mn on (mn.id = cl.manager_id) and (mn.chief_id is not null)
group by mn.chief_id, cl.manager_id) mngrs
inner join
(select cl.manager_id chiefid, count(1) cn
from claim cl
inner join manager mn on (mn.id = cl.manager_id) and (mn.chief_id is null)
group by cl.manager_id) chiefs on chiefs.chiefid = mngrs.chief_id
where mngrs.cn > chiefs.cn