Data storage advice needed: Best way to store location + time data?
I have a project in mind that will require the majority of queries to be keyed off of lat/long as well as date + time.
Initially, I was thinking of a standard RDBMS where lat, long, and the datetime field are properly indexed. Then, I began thinking of a document based system where开发者_开发百科 the document was essentially a timestamp and each document has lat/long with in it. Each document could have n objects associated with it.
I'm looking for advice on what would be the best type of storage engine for this sort of thing is - which of the above idea would be better or if there is something else completely that is the ideal solution.
Edit: Looking for an open source/free solution. Unfortunately price is an issue!
Thanks
I have used PostGres (free open source db) with PostGIS extensions for working with location data. They are extremely good, even though I was working in an MS environment with all production databases using MSSQL 2005, I used PostGres w/GIS to manipulate and precalculate a lot of geographic data.
PostGis has utilities for import arcview .shp files which is a huge plus since that's how most geographic data is present. It also provides a host of location based sql functions like contains( ... ) and near( ... ); and it provides a mechanism for indexing spatial data.
It's been awhile since I used it, but I remember it being rock solid and very useful.
PostGIS: http://postgis.refractions.net/
SQL Server 2008 has new data types for storing and processing geographic information, in addition to the usual date and time types.
See "Working with Spatial Data (Database Engine)".
SQL Express is a free database + has suppport to store lat/long & dateTime
just a tip - use UTC time for dateTime specially if your application needs to be aware of various locations...
hth.
精彩评论