Click here to Skip to main content
15,120,078 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi Team

I want to know if there is way in azure portal, to convert JSON file into CSV file without using any tool like VS etc?

What I have tried:

I have followed this link on stackoverflow, are there any options available? PLease advice and let me know, thanks.
Database migration tool for Azure Cosmos DB | Microsoft Docs[^]
Posted
Updated 18-Oct-19 2:29am
v2

1 solution

Try this (no guarantees):
C#
DataSet ds = JsonConvert.DeserializeObject<DataSet>(json);
DataTable dt = ds.Tables[0];
FileHelpers.CsvEngine.DataTableToCsv(dt, filename);
   
Comments
gcogco10 18-Oct-19 8:05am
   
Am i doing this on azure query separately or...? i meant to say i dont want to use any code on Visual Studio, just some implementation on azure itself like a service that can do this work. Hope im clear
#realJSOP 18-Oct-19 8:18am
   
Azure is just cloud based storage. How you get your data into the cloud is entirely on your shoulders. If you need to submit your data as a csv, YOU have to convert it to that format.
gcogco10 18-Oct-19 9:18am
   
I was looking something along this line#RealJSOP

https://www.yash.com/blog/migrate-sql-data-to-azure-cosmos-db/

But Migration Tool on my side does not seem to convert my JSON format to CSV file as expected. Any reason for this behavior? What is the difference between Azure storage explorer and Migration Tool?
#realJSOP 18-Oct-19 10:27am
   
I have no idea. I've never worked with Azure, but I do know it's just a remote storage solution. You still have to write code to get your data into the database.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900