Have a python list of dict as following:
Dict1 = [{'date': 1, 'name': 'xyz', 'qty': 100},{'date': 1, 'name': 'xyz', 'qty': 200},{'date': 1, 'name': 'xyz', 'qty': 300},{'date': 1, 'name': 'xyz2', 'qty': 30},{'date': 2, 'name': 'xyz', 'qty': 1000},{'date': 2, 'name': 'xyz2', 'qty': 300},{'date': 3, 'name': 'xyz', 'qty': 500},{'date': 3, 'name': 'xyz2', 'qty': 500},{'date': 3, 'name': 'xyz3', 'qty': 500},{'date': 3, 'name': 'xyz', 'qty': 600}]
Would like to to get running total of qty for each name for each date:
date:1,name:xyz,qty:600
date:1,name:xyz2,qty:30
date:2,name:xyz,qty:1600
date:2,name:xyz2,qty:330
date:3,name:xyz,qty:2700
date:3,name:xyz2,qty:830
date:3,name:xyz3,qty:500
Thanks.