[ale] Another Large File/PERL/Awk/Sed question...
Bob Kruger
bkruger at mindspring.com
Tue Dec 1 16:06:39 EST 2009
All;
Thanks to all who assisted me with my earlier question on deleting the semicolon from the end of a line. I have another one that may be a bit stickier.
Again I have a large data file in text format, this one is 3.2GB. Same as before, the field are semicolon delimited. The first line of the file is the column name. However, I have two columns that were inadvertently given the same column name.
Example:
column1;column2;column3;column4;column4;column6;column7....
I would like to change the second instance of column4 to column5 on the first line of the file. I thought it would be simple to fire up vi and just do a simple text edit. The edit part was simple, but the saving of the file is taking hours.
Any thoughts or ideas using PERL, Awk, or Sed?
Thanks in advance for any assistance.
V/r
Bob
More information about the Ale
mailing list