query for areas: fixed a bug.