[OSM-dev] [OSM-talk] Trouble in Rangoon
Marcus Wolschon
marcus at wolschon.biz
Thu Feb 28 12:47:23 GMT 2008
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
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?
Why not?
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
| want.
SELECT *, MAX(version)
~ FROM nodes
~ WHERE tile IN (...)
~ AND timestamp <= XYZ
~ group by node_id
Marcus
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFHxq1af1hPnk3Z0cQRAuvbAJoDVcYaRQU0QkdnNK/0aZjv/j0VdQCfSf5A
RzFBeCc31xMBEw9/KPFhHbA=
=XcHT
-----END PGP SIGNATURE-----
More information about the dev
mailing list