csv output

2015-03-23 Thread Kyle Sexton
Given output from the repl of a data structure like this: #+BEGIN_SRC clojure foo.core (list-users) [{:path /, :create-date #DateTime 2015-03-18T10:11:10.000-05:00, :user-id FOOFOOFOO, :user-name foo} {:path /, :create-date #DateTime 2013-05-29T13:39:00.000-05:00, :user-id BARBARBAR,

Re: csv output

2015-03-23 Thread Christopher Small
I'll make a couple of recommendations here: 1. Try out @davidsantiago's clojure-csv: https://github.com/davidsantiago/clojure-csv. I think it has more formatting/parsing flexibility, and you may find that it just works (TM). 2. For getting from maps to a sequence of vectors

Re: csv output

2015-03-23 Thread blake
I just did this but for a more complex data structure so it doesn't quite map to your example. I did it this way: 1. Stringify-keys 2. Merge the data, then pull the keys to get the unique fields 3. Join all the keys got in part 2 with , to create a header record 4. Now, for each record, pull the