If I do this and the value I'm searching for doesn't exist then I've re-written the entire contents of the original file needlessly. Hence is there anyway to redo the same loop so the first time round I see if the value exists and if it doesn't I don't bother creating an output file ? So a redo for the whole loop rather than the current iteration of the loop ?open file While (<file>) { if value exists then modify and print record to output file else print record to output file } rename output file back to original filename
In reply to redo entire loop by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |