I have am redirecting the file inside file but at the last the file is going to nullify, my code is like below
#!/bin/ksh
newlycreated=`cat /axphome/gdevarad/file.txt|awk '{print $1}'`
for i in $newlycreated
do
cat file1.txt |grep -v $i > /axphome/gdevarad/file1.txt
done
file.txt
contains
india 30
pakistan 40
file1.txt
contains
india 30
pakistan 40
germany 50
japan 60
aus 70