I've got this select with subselects,and I want to get the first 5 values.That's OK.But when I try to do the same in one of the subselects I always get ORA-00907 with the order by...

select * from(select provincias.descripcion as Provincia,count(provincia) as numero,
(Select count(provincia) from empresas where provincia not in
(select(Select provincia from empresas group by provincia order by count(provincia) desc)where rownum <=5) as resto
from empresas,provincias where empresas.provincia=provincias.codigo
group by provincia,descripcion order by count(provincia) desc)
where rownum <=5;

Can somebody help me to do it right? Thanks