Hemond, Steve wrote:

Example :
10652PUPD515,10652PUPD515,2536PUSP61PU57531,8270PDPA57 ----


to :
10652PUPD515,10652PUPD515,2536PUSP61;NEW_COMMAND;PU57531,8270PDPA57
                                ----------------

My actual way of doing it is :
s/SP(\d*)/SP$1;NEW_COMMAND;/)


A hint:



REGULAR EXPRESSIONS QUANTITY MODIFIERS


CHARACTER MEANS

* Match 0 or more times

+ Match 1 or more times

? Match exactly 0 or 1 time

{N} Match exactly N times

{MIN,} Match at least MIN times

{MIN,MAX} Match between MIN and MAX times inclusive


-Bill- __Sx__________________________________________ http://youve-reached-the.endoftheinternet.org/

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>




Reply via email to