function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
twiq90twiq90 

Exporting with the Apex Data Loader results in HTML in the CSV file

I used the Apex Data Loader to export some data from our org.  Most of the data in the CSV lines up just fine in columns and rows when I open it in Excel, but some data has HTML <p> tags in it and is not staying in the correct field and starts a whole new row.

 

I understand that some HTML tags are allowed in certain SFDC fields.  How can I get the data for this field not to start a new row?

Best Answer chosen by Admin (Salesforce Developers) 
twiq90twiq90

I've found an answer to my own question.  

 

The org that I'm working in contains objects with a mixture of rich-text and non-rich-text fields.  I was using the Apex Data Loader to export all of the fields for an object to one file in one fell swoop.  I think that the mixture of character encodings, both UTF-8 and Rich Text, in one file caused the problem that I originally described.  To solve the problem, I exported the rich text fields to one file using rich text (or ISO-8859-1) encoding and then exported all of the other fields to another file using UTF-8 encoding.  

 

If you need to manipulate the files and save changes before importing them, be sure to use an editor that can both import the appropriate character set and save as a CSV in that character set after you make your changes.