How do I get rid of just one character?
November 11, 2008 7:06 AM
Subscribe
I need a way to remove one character from a fixed width file, and put a zero in another spot to compensate. How would I get this done?
I've got this file, full of record sets like this:
http://pastebin.ca/1253309
In the RDG record, you see the 0000017549 from positions 34-43. What I need is for the 9 to be removed, and a zero to be put in the front of the reading to look like 0000001754 . It's always going to be the 43rd character that is lost, and it's always going to be a zero to be put added in at position 34. Would the hive mind please help a person out?
posted by deezil to computers & internet (9 comments total)
1 user marked this as a favorite
posted by kamelhoecker at 7:22 AM on November 11, 2008