ST_euclideanDistance

更新时间:
复制 MD 格式

Returns the nearest Euclidean distance between two trajectory objects at the same time point.

Syntax

float ST_euclideanDistance(trajectory traj1, trajectory traj2);

Parameters

ParameterDescription
traj1The first trajectory object.
traj2The second trajectory object.

Usage notes

The returned distance value is standardized.

Examples

The following example returns the standardized Euclidean distance between two trajectories stored in traj_table.

SELECT ST_euclideanDistance(
  (SELECT traj FROM traj_table WHERE id = 1),
  (SELECT traj FROM traj_table WHERE id = 2)
);

What's next