ST_leafCount

更新时间: 2026-08-24 09:50:23

Returns the number of leaves (trajectory points) in a trajectory object.

Syntax

integer ST_leafCount(trajectory traj);

Parameters

ParameterDescription
trajThe trajectory object.

Examples

The following example queries the number of leaves in the trajectory where id = 2. The result shows the trajectory has 16 trajectory points.

SELECT st_leafCount(traj) FROM traj WHERE id = 2;

Output:

 st_leafcount
--------------
           16
上一篇: ST_leafType 下一篇: ST_duration