select selstaff,count(t.selstaff) as total from
(
select staff_id1 as selstaff from tb
union all
select staff_id2 as selstaff from tb
union all
select staff_id3 as selstaff from tb
union all
select staff_id4 as selstaff from tb
)
as t
group by selstaff
order by total desc limit 0 ,10