Can N1QL leverage geospatial views for indexing?

I came acroos a thread and it mentions that the N1QL can leverage both indexes - GSI and Views.
(When use Couchbase Views instead of N1QL?)

My query need is like “find books by auther in a NewYork city”.
as i understand, its not possible to satisfy this query only using the geospatial view as they dont support non-numeric fields to be indexed.

Is it possible to achieve the same using N1QL query? can N1QL use GSI and geospatial view as compound index?

EDIT: can fulltext indexes be leveraged in N1QL ?

Please check my post: How to I query data by geo location and string value at the same time?

It is possible to query POI in a box (by limiting the lot/lat in a range). But I don’t know how to query with radius(circle)

You need calculate the range in lot/lat based on a “point” and distance.

Hopefully it helps.

1 Like