Convert Json string to CSV string
See original GitHub issueI would like to know how can I convert the json string to a csv string without saving the files to the computer. The code I’m using reads and writes to PC files, but I’d like to use it without dealing with the files.
The code that I was using is this:
using (var r = new ChoJSONReader("sample.json"))
{
using (var w = new ChoCSVWriter("sample.csv").WithFirstLineHeader())
{
w.Write(r);
}
}
I would like a code like this:
public string json2CSV(string jsonData)
{
string csvData;
//Convert jsonData and save in csvData...
//...
return csvData;
}
Issue Analytics
- State:
- Created 5 years ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
How to Convert a JSON String to CSV using Python
Step 1: Prepare a JSON String · Step 2: Create the JSON File · Step 3: Install the Pandas Package · Step 4:...
Read more >How to convert JSON to CSV format and store in a variable
map(fieldName => JSON.stringify(row[fieldName], replacer)).join(',')); csv.unshift(header.
Read more >How to Convert JSON to CSV in Python
Use Pandas to Convert JSON to CSV ; Import Pandas. Import Pandas using import pandas as pd ; Load the JSON string as...
Read more >JSON To CSV Converter
Use this tool to convert JSON into CSV (Comma Separated Values) or Excel. Buy ConvertCSV a Coffee at ko-fi.com · Step 1: Select...
Read more >Pandas - Convert JSON to CSV
pandas is a library in python that can be used to convert JSON (String or file) to CSV file, all you need is...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
LoadText is static member.
For .NET core, use ChoETL.JSON.NETStandard package.
Thanks