Complex spatial and aspatial queries