do some munging to get a csv-like thing