Loading nested JSON objects
See original GitHub issueWhen I load JSON as chart data, I cannot load any nested objects or array values, but only objects in the first “level” of the JSON object.
This works fine:
c3.generate({
data: [{myVal:1}],
keys: {value: ['myVal']} // load property "myVal"
});
But this does not work:
c3.generate({
data: [{myVal: {innerVal:1}}],
keys: {value: ['myVal.innerVal']} // cannot access nested data here
});
There would only be a small change needed to implement the access of nested values, and it would make loading of JSON objects much easier in some cases.
Issue Analytics
- State:
- Created 8 years ago
- Reactions:1
- Comments:11 (4 by maintainers)
Top Results From Across the Web
Python Accessing Nested JSON Data - Stack Overflow
Plop your JSON into the tool in this snippet, check 'brackets only', then click the node you want to copy its code path...
Read more >Extract Nested Data From Complex JSON
Extract Nested Data From Complex JSON. Never manually walk through complex JSON objects again by using this function. Todd.
Read more >Live Demo | How to load nested json Using ADF | Tutorial 13
How to Load Nestes JSON File Using ADF.Convert JSON format to Tabular format in ADFparsing json in ...
Read more >Parsing Nested JSON Fields in Events - Hevo Data
To load JSON-formatted Source data to the Destination, you must select how Hevo must parse the nested fields, objects, and arrays so that...
Read more >Storing and retrieving Nested JSON document
Follow the below steps to understand how nested JSON objects can be imported into Redis database: ... Verify if RedisJSON module is loaded....
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
This is a solid idea. Merging PR to
dev
now.Hello,
I am trying to use following JSON data input for stacked bar chart, however its not working for nested input. If I put everything on one level, it works fine. Its just that nested is causing issue. can you pls help?
JSON data - `[ { “Month”: “Sample 1”, “TotalAmount”: “$100”, "StartDate: "EndDate: “Detail”: [ { “Type”: “A”, “Unit”: “50”, “Amount”: “20”}, { “Type”: “B”, “Unit”: “20”, “Amount”: “70”}, { “Type”: “C”, “Unit”: “2”, “Amount”: “10”}, ] }, { “Month”: “Sample 2”, “TotalAmount”: “$150”, “Detail”: [ { “Type”: “A”, “Unit”: “50”, “Amount”: “20”}, { “Type”: “C”, “Unit”: “2”, “Amount”: “10”}, ] },
]`