获得轨迹的空间参考标识符(SRID)。执行空间相关操作时,将使用SRID查找空间参考系信息,确保正确执行计算。

语法

int ST_SRID(trajectory traj);

参数

参数名称 描述
traj 轨迹对象。

描述

  • SRID对应的地理坐标系统和投影信息保存在系统表spatial_ref_sys中。
  • SRID默认值为0。

示例

select ST_SRID('{"trajectory":{"version":1,"type":"STPOINT","leafcount":2,"start_time":"2007-05-27 00:00:00","end_time":"2007-05-28 08:36:47.846","spatial":"LINESTRING(13.43593 52.41721,13.43593 52.41721)","timeline":["2007-05-27 00:00:00","2007-05-28 08:36:47.846"]}}'::trajectory);
 st_srid 
---------
       0
(1 row)