Looping through an array of json objects

Looping through an array of json objects

sadepusadepu Posts: 1Questions: 0Answers: 0
edited April 2014 in DataTables 1.9
I have JSON object returned by AJAX call like below


{"type":"type2","ratings": [


I need to draw the data table like below using the above JSON object. JSON object may have n number of types.

Date Rating Rating Type
1-Jul-13 A FLT
2-Jul-13 B LLT
3-Jul-13 C MLT
4-Jul-13 D NLT
Date Rating Rating Type
5-Jul-13 AA RT1
6-Jul-13 BB RT2
7-Jul-13 CC RT3
8-Jul-13 DD RT4

Please let me know how to loop the above JSON object and display the columns.


  • allanallan Posts: 55,045Questions: 1Answers: 8,638 Site admin
    DataTables currently doesn't do nested data. You would need to flatten your array / object structure.

This discussion has been closed.