if you have Python
Code:
#!/usr/bin/env python
import string
FROM="12345"
TO="67890"
table=string.maketrans(FROM,TO)
for line in open("file"):
line=line.strip().split(",")
line[1]=line[1][:4].translate(table) + ''.join(line[1][4:])
print ','.join(line)
output
Code:
# python test.py
"1234,0678,0987,12345667,000000976655,+1234,013994878356"
"0987,78967,11243554,0000887651,1234567,09876,1234455"
"0987675,6778443,797784784784,09866545,+232322,097865"
|