Exporting models

Silverstripe Version:
3.1

Question:
I have a “client” model linked to “products” with a many to many relationship and I need to export in a single CSV all the data so we can see which client has which product. In admin, what is the best way to approach this? I can export the “client” table with the default “export” button but I would ideally like to build my own export where I can have my client details & all the products listed in columns, and a Y or N in each client dell indicating if the client has the product.