is it possible to obtain this output ? With a command line tool (jq or other)
From csv
id,age,gender
1,39,M
2,25,M
To json column array
[{"id":["1","2"]},{"age":["39","25"]},{"gender":["M","M"]}]
OR from json
[
{
"id": "1",
"age": "39",
"gender": "M"
},
{
"id": "2",
"age": "25",
"gender": "M"
}
]
To json column array
[{"id":["1","2"]},{"age":["39","25"]},{"gender":["M","M"]}]
Hoping you understood me. Thank you in advance for your answers.