Re-added CSV generation
More hacking on CSV