prepare to XML, CSV output