include geo distance

This block is part of the query group and was last modified in core v12.0.4.

Field Selection Required

This block relies on a field that you select to perform its data actions. You must manually select the field you want to use in your flow using the field selector modal. To access the modal, click the white button on the block.

Connection Type

This block connects from a query type block. Make sure to connect this block to the appropriate left-hand side connection.

include geo distance v12.0.4

Adds a field "distance" which returns the distance in meters based on the given geo_point

In pins 1
  • Location required
    geo_point

    The location (geo_point) used to define the distance

Out pins 1
  • query
    query

Emits the fragment {"include_geo_distance": {"field": <bound geo_point field>, "geopoint": <location pin>}}, which the search layer turns into a per-hit script field "distance" (meters from the given location). It ENRICHES results only : it does not filter or sort them. Elasticsearch only.

A typical wiring for Include geo distance: from city feeds the location pin; the query out pin feeds cast to object.

Studio canvas example for the Include geo distance block: typical wiring for Include geo distance.

Version history

Introduced in v12.0.4.


Back to query Return to the main group to view all sub-groups Back to query: misc. Return to the group to view all blocks within this group