The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM



View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #4 (permalink)  
Old 09-04-2007
aajan aajan is offline
Registered User
 

Join Date: Jun 2007
Posts: 80
Try this!!!!!!!!!!!!!!!


sed 's/\(<moid>\)\(.*\)\(<\/moid>\)/\2/g' input file | cut -d"<" -f1 >countersource.txt


sed 's/\(<r>\)\(.*\)\(<\/r>\)/\2/g' input file |grep "[0-9]" |sed 's/\(<moid>\)\(.*\)\(<\/moid>\)\(.*\)/\4/g' >countername.txt
Reply With Quote