Skip to content

Instantly share code, notes, and snippets.

@soiqualang
Created November 13, 2019 02:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save soiqualang/162e380f6f76a15594d3f6d4a62d38a3 to your computer and use it in GitHub Desktop.
Save soiqualang/162e380f6f76a15594d3f6d4a62d38a3 to your computer and use it in GitHub Desktop.
PostgrteSQL/ PostGIS create bbox column
SELECT
gid,
"OBJECTID",
"MA_DVHCP",
ten_quan,
"Shape_Leng",
"Shape_Area",
the_geom,
imgvitri,
id,
distname,
distalias,
replace(replace(replace('' || box2d(the_geom),'BOX(',''),')',''),' ',',') as bbox
FROM
public.vs_district
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment