Settings

Allows you to limit the number of returned records and search distance, as well as include distance to edge, count, and index fields to the output.

Table 1. Find Nearest Settings
Output Option Description
Limits These settings limit the maximum number of records that may be returned for any search geometry. To ensure the best performance for your flow and the system, it is highly recommended that at least one of these limits is set.
Limit the number of returned records

By default this option is selected with a default value of 1. If it is not selected, all nearest candidates that are within the specified distance are returned. This might affect performance.

A value specified in the MaxCandidates input field will override this setting.

Limit the search distance

By default this option is selected with a value of 1 mile. Valid values are > or = 0, however a search distance of 0 will return only results that intersect the input geometry. Available units are miles, centimeters, feet, inches, kilometers, meters, or yards.

Values specified in the MaxDistance and MaxDistanceUnit input fields will override this setting.

Distance

Include distance

This option (which is selected by default) is useful when you want to know the shortest distance from an input geometry to the returned record.

Distance field - contains the shortest distance from an input geometry to the returned record. When the returned record contains or intersects the input, the distance returned will be zero.

Distance unit field - the name of the output field that will hold the distance unit.

Distance unit - Represents the unit of measure of the returned distance (miles, centimeters, feet, inches, kilometers, meters, or yards).

Include distance to edge

This option is useful when you need to know how close a point is to the edge of a geometry. It is not selected by default.

Distance to edge field - the name of the output field that will hold the distance to edge. Always contains the shortest distance to the edge; that is, the distance between the two closest points of the input geometry and the geometry of the returned record. The unit of the returned distance will be same as that selected in the Distance unit drop-down list above.

Geometries with intersecting edges will return zero. If one geometry fully contains the other, the field will return a distance value.

Include count and index

This option is useful when you have many records being returned and need to identify different records from each other.

Count field - the name of the output field that contains the total number of records returned for each input.

Index field - indicates the current record’s order in the collection of output records.

For example, "1 of 5" has a count of 5 and an index of 1.