4 ms·
Well you actually very probably do need PostGIS if you're doing real spatial analysis. PostgreSQL geometry field are just that, 2D geometries, on a plane, in n
by ldng 7y ago
Well you actually very probably do need PostGIS if you're doing real spatial analysis.
PostgreSQL geometry field are just that, 2D geometries, on a plane, in no particular projection system.
Spatial geometries are relative to a projection system. Try to "draw" a square with GPS coordinate and project it in your local official projection reference, you'll probably not get a squared.
Now, if you don't need precision, feel free to use geometries. But be very aware of the trade off you're making. The article, in my opinion, dismisses them a little too fast.
- billfruit 7y agoNot related, but what if I wanted is "projection-less" 3d spatial data, then does PostGIS support it.
- aspirin 7y agoYes, PostGIS supports projection agnostic ”geography” types: https://postgis.net/workshops/postgis-intro/geography.html https://postgis.net/workshops/postgis-intro/geography.html
- earthboundkid 7y agoI think the position of the article is “if you’re just making a web app with some dots on a map, you’re not doing ‘real spatial analysis’”. I basically agree with the post because I found myself in a similar position a few years ago. I inherited a map with dots on it, and I thought “oh, I need to move this to PostGIS.” But it turned out to be overkill. I wasn’t using any geometries, and I didn’t even need distances from a radius. I was just showing events by location, time, and type. Two columns for latitude and longitude were more than enough.
- ldng 7y agoOh fair enough, not really arguing that point. But there is a major trade-off and the article does not even mentions it. It is perfectly fine to consider the GPS coordinate system and basic geometries are good enough for short distance. As long as you're aware that GPS coordinate are actually set in a precise projection system and that you are making a informed decision.