Roger,
> replace($WORD, concat('(^.*?)', 'A'), concat('$1','E'))
is making it look more complicated the it needs to be, you don't need to
use concat (you may want to build up the expression but that's a separate
issue), and it's not any special trick just a normal regex replace as used
in xpath or any text editor (or perl or python or javascript or ...)
replace($WORD, '^(.*?)A', '$1E')
I'd probably have used
replace($WORD, '^([^A]*)A', '$1E')
rather than use newfangled regex forms such as *? for non greedy match, but
that's because I learned regex for (s)ed in the 1980s :-)
David
|