added function for setting the map center according to the query result