[OSM-dev] Semicolon

Dave Stubbs osm.list at randomjunk.co.uk
Tue Nov 20 08:20:50 GMT 2007


On 20/11/2007, Brett Henderson <brett at bretth.com> wrote:
> Tom Hughes wrote:
> > In message <53cf5b6f0711190633g4d99a1bbk7b9fbae3be2b0b72 at mail.gmail.com>
> >         Stefan Baebler <stefan.baebler at gmail.com> wrote:
> >
> >
> >> Hi!
> >>
> >> In a discussion with BrettH about Osmosis handling semicolons in
> >> nodes' tags it struck me that tags of nodes
> >> are kept in a text field in the nodes table(separated with semicolon),
> >> while tags of ways are kept normalized - in a separate table.
> >>
> >> Current escaping is sort of random, see node 100325036 for example.
> >>
> >
> > The current escaping is not random at all - there is no escaping!
> >
> > Well that's not quite true - Potlatch uses a (broken) form of escaping
> > but as it is the only thing that undoes that escaping on read it is
> > not hugely helpful.
> >
> Can I get confirmation of how the escaping is supposed to work?  Is a
> ';' within a tag key or value represented as ";;;"?

Yep, except that not even Potlatch handles it entirely correctly. It
tends to result in an explosion of ; as they self propogate through
mutual expansion :-). An in the general case it's an potentially
ambiguous scheme anyway. In fact it only exists by accident
apparently!

>
> I was intending to fix the escaping in osmosis, although if no other
> tools support it either there may be no point.

I doubt anything is really using any escaping -- your best bet here is
developing a regex to guess when it is supposed to be a new tag. I
made one that mostly worked in a thread ages ago. But if it's not
applied by everyone then there isn't much point.

So until someone fixes the node tags in a way which is acceptable to
the admins there's not much point in bothering with it... just
encourage people not to use ; and = in tag names and values.




More information about the dev mailing list