You can loop.
Or you can access data directly with subscription:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 |
data = { "12345" : { "2021-01-20" : { "a" : 1 , "b" : 3 , "c" : 0 }, "2021-01-21" : { "a" : 1 , "b" : 3 , "c" : 0 } }, "12346" : { "2021-01-20" : { "a" : 1 , "b" : 3 , "c" : 0 }, "2021-01-21" : { "a" : 1 , "b" : 3 , "c" : 0 } } } for customer_id, dates in data.items(): for date, values in dates.items(): for key, value in values.items(): print (customer_id, date, key, value, sep = ", " ) # here is maybe one level too deep # depends on your task |
1 |
value = data[ "12345" ][ "2021-01-20" ][ "c" ] |
Almost dead, but too lazy to die: https://sourceserver.info
All humans together. We don't need politicians!
All humans together. We don't need politicians!