Is there any way to zoom in map using query?

I was unable to find Cancun on map and i had to google its location, I was wondering if there is any way for pin pointing a location using query?
Say initially map renders as shown in below figure labeled A
image

and I want to zoom in to particular coordinate as show in figure below labeled B
image
is there any way of doing this using query.

I don’t think we can search unless mongoDB adds search functionality to the map like how the +/- buttons are there. because GeoJson is based on coordinates only.

1 Like

Hey Anaam, Since I am not familiar with Mexico I too had the same problem. I searched for a Mexico map on Google with keywords ‘map+mexico+cancun’ and found a map. You can find Guatemala & New Orleans on map and draw a imaginary line connecting the 2, you should be able to find Cancun on little left of the imaginary line (circled in green). A crude method but it might help someone :slight_smile:
map_of_mexico

To answer your question, I have gone through the docs and I don’t think there is any way to find a location using query.I wish the future version of Compass would be able to search for a location on map with keyword but that’s asking for too much because that something other databases don’t support either!
Regards
Ajay

1 Like