Re: substitution



John W. Krahn a écrit :
Alexandre Jaquet wrote:


I would like to replace all fields values who begin by $ERROR with empty value:


I've try something like :
s/\$ERROR{'([\w]+)'}/ /;

but didn't work


Perhaps this will work better (untested):

s/\$ERROR{\s*(?:(['"]).+?\1|\w+)\s*}/ /;



John

nope still not but thanks .