troubleshooting Question

search/replace suppl with $suppl

Avatar of GessWurker
GessWurker asked on
8 Comments1 Solution256 ViewsLast Modified:
I need to search for Suppl or suppl in the line starting with <IS and ending with <END> and change to $suppl.


Input: <IS > 1 Suppl 2 <END>
Output: <IS > 1 $Suppl 2 <END>

Input: <IS > suppl 4 <END>
Output: <IS > $suppl 4 <END>

Will add new search/replace to code snip below:
while( <> ){
#version 4: not case-sensitive
       local $_=$2;
       my %seen;
       my @seen;
                 map{$map{lc $_}||($flag=' #unknown',$_)[1]}
       $flag = '# unknown date format';
       if( $var = (split(':',ParseDate($2)))[0] ){
         $var =~ s/(\d{4})(\d{2})(\d{2})\d+/ $2\/$3\/$1 /;
         $flag = '';
   print (OUTPUTFILE);

Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 8 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 8 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros