First off, ^ is the beginning of the string. You only get one string, and the string is [typerank]:[altstreet], so ^ is before the typerank number. The colon is an arbitrary separator between the typerank and the alt name, it does not establish separate strings for the purposes of regex.ispyisail wrote:Hi all
I'm trying to find "alternate" streets names but for some reason I can't get my search to work?
I'm trying to find all alternate street names that that don't finish with "Rd" that are street or primary street.Code: Select all
${typeRank}:${altStreet} /(10|11):(^(.(?!(Rd$)))*$)/
I don't know why it doesn't work, tried may things
Thanks
${altStreet[#]} prints a list of all alt streets separated by the # character (also arbitrary, like the colon above). I added that stuff in and removed some superfluous parentheses. I'm not sure if this will work, because I'm not very good with negative lookaheads, but it's closer.
Code: Select all
${typeRank}:${altStreet[#]}
/(10|11):.(?!(Rd(#|$)))*(#|$)/
Re: [Script] WME Validator 1.1.7 / 06.03.2015