Convert complex json with multiple levels as individual headers into CSV

Hi Team,

  1. we are facing a Challenge while trying to convert complex JSON with hierarchy data into multiple header and lines CSV format - below is an example with sample data

If the input JSON has hierarchy as seen in the sample data in the image, Employee can have manager data mapped(marked in yellow)
Highlighted in blue is the expected CSV output, employee data has to be defined as header 1 and manager data has to be defined as header2 and the data for these two headers have to placed as individual rows -Line items
image.png (6.7 KB)

Please let us know how can this be achieved using aspose

@vitusfnathan,

See the document on how to import JSON to Excel spreadsheet via Aspose.Cells APIs.

Do you import JSON into a CSV via Aspose.Cells APIs? Also, if you import your JSON (data) into Excel sheet manually in MS Excel, does it paste data in your desired style? Please note, if MS Excel can accomplish the task when importing JSON into Excel sheet, then Aspose.Cells can also do that. If MS Excel cannot do that, Aspose.Cells will not do that either as it follows MS Excel standards and specifications.

In case, Aspose.Cells does not work similar to MS Excel, please provide your JSON file and paste your runnable sample code and sample files (input and output CSV file), we will check it soon. Also provide your expected file via MS Excel manually (where you import JSON file into Excel sheet via MS Excel options).

PS. please zip the files prior attaching.