Hi, I'm appending json to html table but the thing is i want to get the item grouped by CategoryID and one thing to mention here i want to sum the values and add an row after here.
- var dataString='[
- { "catID" : "2454", "Name" : "Samsung", "Price" : 28$ },
- { "catID" : "2454", "Name" : "Nokia", "Price" : 17$},
- { "catID" : "2454", "Name" : "iPhone", "Price" : 95$},
- { "catID" : "3888", "Name" : "Canon", "Price" : 550$},
- { "catID" : "3338", "Name" : "Haier", "Price" : 390$},
- { "catID" : "3888", "Name" : "Nikon", "Price" : 290$},
- { "catID" : "4999", "Name" : "Hp", "Price" : 311$},
- { "catID" : "4999", "Name" : "Dell", "Price" : 320$},
- { "catID" : "3338", "Name" : "Orient", "Price" : 350$}
- ]';
i want to add a row after each category for the sum(Price) of that category.
Any help will be appreciated
Thanks