How to wrap text with in a column while writing in csv file using python
CSV is not formatted. If you want to format the text in the cells, you should consider writing a proper Excel or PDF file.
Anyway it looks like that newline characters (\n or \r\n) can be used in CSV files if using semicolon as separator, so this may not be portable.
To write an Excel file, you can use libraries like openpyxl or xlwt.
I am trying to export a file as csv. I need to wrap text for a particular column while writing in csv file. I have a too long string. i need to write it in a csv file using python. While trying to write, it doesn't write in a single cell. some of the lines are written into next rows. I need to write the whole string in a single cell. Please help me to do this.