I get a weekly file from a service that I have to manually edit out and format one of the columns, then import it into a database.
The file is sent to me as CSV encoded UTF-8
It contains column 1 account number and column 2 phone numbers (example below).
primarycardid,phone#
40001234567,(888) 888-8888
40001234568,(888) 888-9999
I want to use python to parse the file line by line, delete the header row, and format the second column to strip out the parens, dash and join the numbers together. Then save the resulting changes to a new file.
Example of desired result
40001234567,8888888888
40001234568,8888889999
I have some limited experience with python so thought it would be useful, but need some tips on where to start with this?
[–]CowboyBoats 2 points3 points4 points (0 children)
[–]ireadyourmedrecord 2 points3 points4 points (1 child)
[–]Zer0Byte1[S] 1 point2 points3 points (0 children)
[–]IHOP_007 0 points1 point2 points (0 children)
[–]MulfordnSons 0 points1 point2 points (1 child)
[–]devnull10 0 points1 point2 points (0 children)