implemented basic csv export feature