[OSM-dev] [OSM-talk] Trouble in Rangoon
marcus at wolschon.biz
Thu Feb 28 12:47:23 GMT 2008
-----BEGIN PGP SIGNED MESSAGE-----
Tom Hughes schrieb:
| In message <47C69D6C.5040104 at wolschon.biz>
| Marcus Wolschon <marcus at wolschon.biz> wrote:
|> In the end we really need something like
|> the history-tab in wikipedia without breaking
|> referential integrity uppon restores. Once
|> accidents and vandalism becomes more common
|> there is not much of a way around that.
| That's basically not possible - we can't even maintain proper
| referential integrity on ordinary uploads so how you expect to
| maintain it through a bulk restore is beyond me.
We do not check that
* uploaded way_nodes have existing nodes
* uploaded relations have existing items
* removed ways have no way_nodes anymore
* removed nodes have not way_nodes or relations anymore?
The client is responsible for not uploading
crap. If it does, it should get en error-message
and the (remainder of the) upload not be commited.
| For example you can do:
| SELECT *
| FROM nodes
| WHERE tile IN (...) AND timestamp <= ...
| but that will get you all versions of each node that predate
| the given timestamp. Which might be a lot more data than you
SELECT *, MAX(version)
~ FROM nodes
~ WHERE tile IN (...)
~ AND timestamp <= XYZ
~ group by node_id
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
More information about the dev