

When used with BBoxField,additional options are supported:

Otherwise, “x,y” for PointType or “x y” for RPT field types. The center point using the format “lat,lon” if latitude & longitude. (RPT & BBoxField can set other units via the setting distanceUnits) The radial distance, usually in kilometers. Searching documents based on their location:īoth filters support following parameters:

For non-geodetic points, the order is x,y for PointType, and for RPT you must use a space instead of a comma, or use WKT( Well-known text ( WKT) is a text markup language for representing vector geometry objects Ex: POLYGON ((30 10, 40 40, 20 40, 10 20, 30 10)). They can both be used simultaneously for what each does best – LatLonType for sorting/boosting, RPT for filtering.įor indexing geodetic points (latitude and longitude), supply the pair of numbers as a string with a comma separating them in latitude then longitude order. RPT offers more features than LatLonType and fast filter performance, although LatLonType is more appropriate when efficient distance sorting/boosting is desired. SpatialRecursivePrefixTreeFieldType (RPT for short) – Fast filter performance.LatLonType – Better for distance sorting/boosting.Sort or boost scoring by distance between points, or relative area between rectanglesįollowing field types are available for spatial search:.Filter search results by a bounding box or circle or by other shapes.Solr supports location data for use in spatial/geospatial searches. In this article we will see how solr supports spatial search.
