Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
It’s possible to create compound spatial indexes, but only if the coordinate key comes first. You might use a compound spatial index to enable queries on a location in addition to some type of metadata. For instance, imagine that the gardening store introduced earlier in the book has retail locations and that different locations provide different services. A couple of location documents might, in part, look like these:
{loc: [-74.2, 40.3], services: ['nursery', 'rentals']}
{loc: [-75.2, 39.3], services: ['rentals']}