I'm developing an application. In the database I need to store coordinates for many places, in the north-east of Italy, but the area could expand in the future.
This coordinates will come from some geocoding web service (currently Google Geocoding API but could change), but also from the GPS of Android devices.
How would you save this points in PostGIS?
Data type: geometry or geography?
They say that geometry is faster in calculation, but I immediately faced the fact that ST_Distance returns degrees instead of meters in case of geometry arguments... So I have to cast to geography and loose such performance advantage! Or maybe should I use ST_Distance_Sphere with geometry?
SRID: how do you choose one?
Which SRID do geocoding web services and GPS for Android phones use (if they use it)? Is it possible to always work on coordinates with the same SRID?
أكثر...
This coordinates will come from some geocoding web service (currently Google Geocoding API but could change), but also from the GPS of Android devices.
How would you save this points in PostGIS?
Data type: geometry or geography?
They say that geometry is faster in calculation, but I immediately faced the fact that ST_Distance returns degrees instead of meters in case of geometry arguments... So I have to cast to geography and loose such performance advantage! Or maybe should I use ST_Distance_Sphere with geometry?
SRID: how do you choose one?
Which SRID do geocoding web services and GPS for Android phones use (if they use it)? Is it possible to always work on coordinates with the same SRID?
أكثر...