How to write an extra header to a csv file

How to write an extra header to an existing csv file.

Hi

I hope you mean like adding a new row at the top of the DATATABLE

Hope the below steps would help you resolve this

  1. First let’s read the CSV file with read CSV file activity and get the output as DATATABLE named dt

  2. Now we can add a row to the top of the
    Refer this thread
    How to get the last Wednesday of each month - #2 by Anthony_Humphries

3 then write back to a CSV file with write CSV activity

Cheers @Sumit_Ghosh1

Nope.

I am trying to read csv, but its failing as there is an extra cell value(in one of the row) than the columns number.

ie, column numbers = 9
Row 4 column numbers = 10(extra 1 cell value)

So I am trying to add a column header so that the read csv dont fail.

I think it is more probably that you have a comma in the middle of a field value or csv is malformed.

In those cases it is convenient to process csv by reading it as a text file and parsing line by line in order to determine which lines are correct and if you can do something about if it is not right