ST_SetSRID

更新时间:
复制 MD 格式

Sets the spatial reference identifier (SRID) of a trajectory.

Syntax

trajectory ST_SetSRID(trajectory traj, int srid);

Parameters

Parameter name

Description

traj

The trajectory object.

srid

The target SRID.

Description

Sets the SRID of a trajectory to a specified value. This operation does not affect any other properties of the trajectory.

Example

select ST_setSRID('{"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":"SRID=4326;LINESTRING(13.43593 52.41721,13.43593 52.41721)","timeline":["2007-05-27 00:00:00","2007-05-28 08:36:47.846"]}}'::trajectory
,4002);
                                                                                                                           st_setsrid                                                                                                                           
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 {"trajectory":{"version":1,"type":"STPOINT","leafcount":2,"start_time":"2007-05-27 00:00:00","end_time":"2007-05-28 08:36:48","spatial":"SRID=4002;LINESTRING(13.43593 52.41721,13.43593 52.41721)","timeline":["2007-05-27 00:00:00","2007-05-28 08:36:48"]}}
(1 row)