Domanda

MongoDB uses the WGS84 datum for geospatial queries on GeoJSON objects. What should I do when my data is stored in other datum? Can I create spatial index specifying datum or when making queries specify datum?

Best Regards, Edijs

È stato utile?

Soluzione

MongoDB does not support any other datum than WGS84 (and WGS84 is de facto standard these days). If your data uses different reference ellipsoid then I could only advise converting it to WGS84 before storing it in MongoDB if you would like to use geospatial features in MongoDB.

Here is somehow a related topic converting WGS72 to WGS84: Converting between coordinates system WGS 74 and WGS 84

If this does not meet your app requirements then check out PostGIS.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top