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 the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 01-24-2007
happyv happyv is offline
Registered User
  
 

Join Date: Sep 2006
Posts: 209
read file and output message

hi,

I have a baby.txt file with two type of message:

xxxxxxxx is missing
xxxxxxxxxxx is not missing
xxxx is missing
xxxxxxxx is not missing
xxxxxxxx is not missing

For the above, I need to read file and get all "xxxx is missing" and write into baby_missing.txt. If no message "xxxxx is missing" in whole baby.txt, the script will write message "no file is missing in system" to baby_nomissing.txt

is it possible? if yes..how?