Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to get Longitude/Latitude from Geography Data in PostGIS

Tags:

postgis

I need the longitude and latitude of the centre of geography data in PostGIS. The format is called EPSG 2206 and the columns in record are "length","shape_area" and "the_geom"

like image 748
Rainald Siebert Avatar asked Jan 15 '23 03:01

Rainald Siebert


1 Answers

i use the query to get longitude and latitude.

Longitude

SELECT ST_X(the_geom) FROM myTable;

Latitude

SELECT ST_Y(the_geom) FROM myTable;
like image 125
AmirtharajCVijay Avatar answered May 12 '23 23:05

AmirtharajCVijay