[postgis-users] Capturing point in time information for groups of geometries.

Paul Ramsey pramsey at refractions.net
Mon Jan 31 15:19:19 PST 2005


Brute force solutions to temporal problems are commonplace. There are 
not a lot of generic elegant solutions, unfortunately, the solution that 
suites you best will depend on your problem domain.

Many operational spatial database systems want to maintain "time travel" 
capability -- the ability to find the state of the data at any past 
time.  One common way of doing this is to give every field an extra pair 
of attribute datestamps, an "admission date" and a "retirement date". 
Then, finding a version of the database becomes a fairly simple exercise 
in SQL.

However, such a database can be a pain to work with for day-to-day 
operational tasks (because it is full of legacy information as well as 
current information).

A simple way of trading disk space for complexity is to keep two copies 
of your database around.  A copy that is a "current operation" version, 
and a "versioned" copy.  By putting update/insert/delete triggers on all 
your "current operation" tables, you can cause the "versioned" copy to 
be kept in sync with the changes that occur on the operational data. 
This is a nice way to maintain versioning without imposing the overhead 
of a versioning system on your end users.  Of course, it has *other* 
overheads, in terms of space and performance.

Everything is trade-offs.

Yours,

Paul

Eric Merritt wrote:

> I need to capture point in time information for groups of geometries
> (maps basically). The goal is to see how things change over time. I
> havn't come up with any simple and reliable way to do this as yet. I
> have a couple of simple and strait forward ways to do it but they are
> more brute force, non-optimal approaches. Do any of you have similar
> requirements? Would you mind sharing your solutions?




More information about the postgis-users mailing list