Search code examples
postgresqlopenstreetmap

The coordinate of the data in osm point is too large


I am working on postgresql for several days

I imported the data from open street map (osm)

everything works well until I translate the geometry type

the value it gives is very large. I have no idea what it is

img for the problem


Solution

  • The coordinates are in the Web Mercator projection (3857) not in lat-long (4326). This projection uses meters from a reference point (lat-long 0;0)

    Some tools such as osm2pgsql will use the Web Mercator by default.