Skip to content

Compute distance between geospatial points

Description

The Compute Distance Between Geospatial Points activity calculates the distance between geospatial locations in your dataset using user-defined comparison methods. The comparison can be done against a fixed point, a fixed geospatial object, or another geospatial column in the same row.

This activity is useful for spatial analysis, proximity-based filtering, logistics planning, and mapping applications.

Use this activity to:

  • Compute distance from a known reference point (e.g., a warehouse or city).
  • Measure distances between points in two different columns.
  • Evaluate proximity to predefined geospatial shapes or objects.

Use case: Determine how far customer addresses are from a delivery hub by comparing latitude/longitude columns with a fixed reference point.

Input

Input TypeRequiredDescription
DataRequiredTabular data with geospatial coordinates (latitude and longitude) or geospatial columns

Output

Output TypeFormatDescription
DataJSONTransformed dataset with distance column

Configuration Fields

Field NameDescription
Compare TypeType of comparison to perform. Options:
  • Fixed Geo Point
  • Fixed Geospatial Object
  • Another Geospatial Column
Fixed GeopointUsed when compare type is Fixed Geo Point. Latitude and longitude values are taken from the next two fields.
Latitude ColumnColumn in your data containing latitude values (used with Fixed Geo Point).
Longitude ColumnColumn in your data containing longitude values (used with Fixed Geo Point).
Latitude Value For FixedGeopointLatitude of the fixed point (e.g., 12.9716).
Longitude Value For FixedGeopointLongitude of the fixed point (e.g., 77.5946).
Geo ColumnColumn containing geospatial objects (used with Fixed Geospatial Object).
Column For ComparisonAnother geospatial column to compare with (used with Another Geospatial Column).
Distance Column NameName of the new column that will store the calculated distances.

Sample Input

IDLatitudeLongitude
128.704177.1025
234.0522-118.2437
348.85662.3522
451.5074-0.1278
540.7128-74.0060

Sample Configuration

FieldValue
Compare TypeFixed Geo Point
Latitude ColumnLatitude
Longitude ColumnLongitude
Latitude Value For FixedGeopoint12.9716
Longitude Value For FixedGeopoint77.5946
Distance Column NameDistanceFromBangalore

Sample Output

IDLatitudeLongitudeDistanceFromBangalore
128.704177.10251756.4
234.0522-118.243714572.1
348.85662.35228023.5
451.5074-0.12788276.3
540.7128-74.006013386.7