This line of code:
print (grep /$backup_job/, <NB_FILE>);reads the whole file and positions the filehandler at the end of the file. Therefore, next time in the for loop, you don't read anything from the file. You should probazbly loazd your file into an array and then read through the aerray.
In reply to Re: Help with for loop
by Laurent_R
in thread Help with for loop
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |