How to export all the purchase information?

You can’t export a multiline invoice in a CSV file as it’s a flat file type, explained in more detail here.

You could write a program to work against our API, this would allow you to pull all the header and item line information in a structured XML document.

API: Purchase Methods