Wednesday, December 2, 2015

PostGIS notes

SRID 4326

x = longitude
y = latitude
Like JTS.

UPDATE some_table
  SET geom = ST_SetSRID(ST_MakePoint(lon, lat),4326);

INSERT INTO some_table (geom)  VALUES (ST_MakeEnvelope(SW_lon, SW_lat, NE_lon, NE_lat, 4326));

SELECT ST_Extent(geom) as table_extent FROM some_table;

No comments:

Post a Comment