The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM



View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #4 (permalink)  
Old 05-14-2008
penchal_boddu penchal_boddu is offline
Registered User
 

Join Date: Apr 2008
Location: Bangalore
Posts: 120
using for loop

for i in `cat filenames.txt`
do
..
grep .......... $i
..
done

Using while loop

while read line
do
..
grep ....... $line
..
done < filenames.txt



Thanks
Penchal
Reply With Quote