Modifies longitude coordinates in geometries, shifting values between -180..0 degrees to 180..360 degrees and vice versa. This is useful for normalizing data across the International Date Line and standardizing coordinate ranges for visualization and spheroidal calculations.
This function is only applicable to geometries that use lon/lat coordinate systems.
Signatures
ST_ShiftLongitude (geom: geometry)
Parameters
Return type
Examples
SELECT ST_ShiftLongitude(ST_GeomFromText('LINESTRING(177 10, 179 10, -179 10, -177 10)'))
LINESTRING(177 10, 179 10, 181 10, 183 10)