Convert a .csv in Python (Very small project)
Budget: $10 – $30 USD
Make a program in Python3 to convert one .csv file to another format.
input file = samplefile.csv
output file = samplefile-n.csv
Fields to arrange in the correct order
"CLIENTE" = "nao usado"
"MODELO" = the fifth column
"SERIE" = the first column
"DATA" = the second column
"MONO" = the fourth column
"COLOR" = the fourth column
"SCAN" = the fourth column
"TOTAL" = the fourth column
Output Input
"MONO" = "Cont. P&B"
"COLOR" = "Cont. Cor"
"TOTAL" = "Contador Geral"
"SCAN" = "Cont. Scanner"
Rules:
1) Pay attention with the column "DATA" because they are in different format.
2) If there is only the line "CONTADOR GERAL" for the printer then "MONO" = "CONTADOR GERAL"
input file = samplefile.csv
output file = samplefile-n.csv
Fields to arrange in the correct order
"CLIENTE" = "nao usado"
"MODELO" = the fifth column
"SERIE" = the first column
"DATA" = the second column
"MONO" = the fourth column
"COLOR" = the fourth column
"SCAN" = the fourth column
"TOTAL" = the fourth column
Output Input
"MONO" = "Cont. P&B"
"COLOR" = "Cont. Cor"
"TOTAL" = "Contador Geral"
"SCAN" = "Cont. Scanner"
Rules:
1) Pay attention with the column "DATA" because they are in different format.
2) If there is only the line "CONTADOR GERAL" for the printer then "MONO" = "CONTADOR GERAL"
Related categories:
Python