select c.name as county, min(sqrt(pow(69.1*(p1.latitude-53.85),2)+ pow(53*(abs(p1.longitude--1.54)),2))) as dist
from places p1,county c
where sqrt(pow(69.1*(p1.latitude-53.85),2)+ pow(53*(abs(p1.longitude--1.54)),2)) < 30
and p1.county_id=c.county_id
and p1.name != "Alwoodley"
and c.name != "West Yorkshire"
group by c.name
order by dist
limit 6