With either the Professional or Enterprise plan, Zendesk administrators have the option to export their data to the XML file format. The User XML export exports Groups, Organizations, and Users while the Full XML export exports Accounts, Categories, Entries, Forums, Groups, Organizations, Posts, Tickets, and Users. Review detailed information about these exports in Exporting data to a CSV or XML file (Professional and Enterprise).
While there are multiple online tools that can convert XML files to CSV, these tools will not work with very large XML files. If you have a developer on staff, there are also multiple programmatic solutions for this conversion. However, if you do not have developer resources and would like to convert a large XML file to CSV on a Mac, follow the below steps.
To convert XML files to CSV format on a Mac
- Open Terminal using your Mac's Spotlight Search. You can open Spotlight Search by holding the command and spacebar keys at the same time.
terminalin the Search field and click Enter. Terminal will open.
- In Terminal type
sudo easy_install pipand press enter.
- Type your machine password if prompted and press Enter again. This installs a Python package handler.
sudo pip install xmlutilsand press Enter.
- Type your password if prompted and press Enter. This installs the conversion tool.
- Create a folder on your desktop and name it "xml."
- Place the large xml file that you would like to convert in this "xml" folder. For example, place your users.xml file in this folder.
- In Terminal type
sudo xml2csv --input "users.xml" --output "users.csv" --tag "user"
and press Enter.
- Type your password if prompted and press Enter again. This executes the conversion. Terminal will display how many records were written.
- Browse to the "xml" folder on the desktop to open the converted CSV file.
sudo xml2csv --input "tickets.xml" --output "tickets.csv" --tag "ticket"Adjust this code as necessary for your type of export.