
On 25/05/14 11:14, Colin Smale wrote:
I am trying to normalise street names by removing any dots. So far I have been unable to get the subst function to do what I want. The problem seems to be getting the dot to be taken literally in the subst parameters.
I have tried:
a) set newname='${name|subst:. +=> }'
Originally subst was a straight forward string replacement. So ${name|subst:.=> } would replace each dot with a space. Also because multiple spaces are combined into one elsewhere this actually has the effect you want in this case. Regular expressions were added later and you need to use ~> instead of => to indicate this. So this will work: ${name|subst:\.+~> } It may just be an email formating issue, but in your email there is a space after the '.'; make sure that there isn't one in your style file. ..Steve