Hi,
I got a few PDS that I need to edit their content to add an edited copy of a line.
When I find "Toronto" I want to make a copy to "DowntownArea"
so in a list like
So and so lives Montreal
Vancouver is a great town
The air in Toronto is humid
I want to go to Regina
Would end up
So and so lives Montreal
Vancouver is a great town
The air in Toronto is humid
The air in DowntownArea is humid
I want to go to Regina
--
What I got at the moment is an extraction of the line with "Toronto" that I modify to DowntownArea:
In that part, it reads once the file and writes it to File01,
Then it reads it again and prints only the "Toronto" lines...
What is perplexing is that the lines end up not at the end of the file but below the lines where we find a Toronto...
For exemple line 12 is copied in line 13... 17 in 18...
Now to finish my job I do an update with a select=2 so only 1 of the 2 lines is modified.