Q:

Top 5 - same formula but different output

In this example I have Data-sheet and Statistics-sheet. I am trying to pull Top 5.
I have tried this: 
=IFERROR(IF(LEN(A2:A)<>"";ARRAYFORMULA(MAX(COUNTIF(A2:A;A2:A)));"");"")

And this:
=IFERROR(IF(LEN(A2:A);ARRAYFORMULA(INDEX(A2:A;MATCH(MAX(COUNTIF(A2:A;A2:A));COUNTIF(A2:A;A2:A);0)));"1");"2")

It works UNTIL I edit the data.
Then I tried this:
=IFERROR(IF(LEN(Data!A2:A)<>"";ARRAYFORMULA(MAX(COUNTIF(Data!A2:A;Data!A2:A)));"");"")

And this:
=IFERROR(IF(LEN(Data!A2:A);ARRAYFORMULA(INDEX(A2:A;MATCH(MAX(COUNTIF(A2:A;A2:A));COUNTIF(A2:A;A2:A);0)));"1");"2")

And now I get a completely different result.
What is the better way to do this?

A:

try:
=QUERY(Data!B:B; 
 "select count(B),B
  where B is not null
  group by B
  order by count(B) desc
  limit 5
  label count(B)''")

for B:E range:
=QUERY({Data!B:B; Data!C:C; Data!D:D; Data!E:E}; 
 "select count(Col1),Col1
  where Col1 is not null
  group by Col1
  order by count(Col1) desc
  limit 5
  label count(Col1)''")

