Convert CSV to JSON with miller

mlr --c2j --jlistwrap cat file.csv
Using the csv tool `miller` you can transform a csv file into a json array of objects, where the properties are the values of the csv header line and the values are the values of the subsequent lines.
Sample Output
 { "H1": "a1", "H2": "a2", "H3": "a3" },
 { "H1": "b1", "H2": "b2", "H3": "b3" },
 { "H1": "c1", "H2": "c2", "H3": "c3" }

By: pepa65
2019-12-06 07:16:58

3 Alternatives + Submit Alt

What Others Think

are there any recent updates with hair extensions atlanta?
looneyhans · 60 weeks and 1 day ago
will starting doing this now.. baby photography thanks for helping me!
idasanka · 55 weeks and 3 days ago
private investigator orlando Just found a site a could relate to
yeoyeo · 53 weeks and 6 days ago
love this soo much! http://https//">fly
sammm · 50 weeks and 5 days ago
Thank you for posting that it could be just the thing to give inspiration to someone who needs it! Keep up the great work!
Caesar · 48 weeks ago
I can't keep up unsecured loans santa maria
geebranz · 35 weeks and 6 days ago
very valuable cabinet companies in virginia beach
geebranz · 35 weeks and 6 days ago
Now nothing has changed, because educational education does not stand still, and I do not always keep up with written assignments, so I use the essay writers for myself, where they write my homework for me
Appencet · 27 weeks and 4 days ago
Thank you so much for sharing this with me. It was very helpful for me to know about these things since I really like to get new tips on commands and programs like this one. So helpful for me.
zaiyamariya · 4 weeks and 1 day ago
You can learn so many such unix commands from here and it's so good to see the details you have shared click here here. The above command is used to convert CSV to JSON with miller. Good to see its sample output over here and I am looking here for more updates on that.
Alyssalauren · 1 day ago

What do you think?

Any thoughts on this command? Does it work on your machine? Can you do the same thing with only 14 characters?

You must be signed in to comment.

What's this? is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

Share Your Commands

Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.


Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: