Complete rewrite of csv output.