title: Add a column in the middle of a row from a .csv file with python
body: <p>Hello I have a python script which changes a timestamp column in a .csv file from dot notation to "date time TSQL" notation:</p>
  
  <p>One row looks like this before executing the code:</p>
  
  <pre><code>send,2007.10.04.10.11.11.669,Server,Data,Client,TYPE=STP,Length=329,Cnt=11
  </code></pre>
  
  <p>after executing the code it looks like this:</p>
  
  <pre><code>send,2007-10-04 10:11:11.669,Server,Data,Client,TYPE=STP,Length=329,Cnt=11
  </code></pre>
  
  <p>I want to append the same time in the new format after the first time column, that it looks like this:</p>
  
  <pre><code>send,2007-10-04 10:11:11.669,2007-10-04 10:11:11.669,Server,Data,Client,TYPE=STP,Length=329,Cnt=11
  </code></pre>
  
  <p>Here is the Script:</p>
  
  <pre><code>import csv
  
  cr = csv.reader(open("ActualTrace_01 - short2Times.csv", "rb"))
  output = csv.writer(open("GermanygoalInputFormatActualTrace_01 - short.csv", "wb"))
  
  for row in cr:    
      dateTimeContentsSend = row[1].split(".")
      finishSend = dateTimeContentsSend[0] + "-" + dateTimeContentsSend[1] + "-" + dateTimeContentsSend[2] + " " + dateTimeContentsSend[3] + ":" 
      finishSend+= dateTimeContentsSend[4] + ":" + dateTimeContentsSend[5] + "." + dateTimeContentsSend[6]
  
      row[1] = finishSend
      output.writerow(row)
  </code></pre>
  
  <p>All Threads here were not useful and if you just say row[1] = finishSend + "," + finishSend
  it makes it in row[1] with quotes like this</p>
  
  <pre><code>send,"2007-10-04 10:11:11.669,2007-10-04 10:11:11.684",Server,Data,Client,TYPE=STP,Length=329,Cnt=11
  </code></pre>