I am using azure cosmos db in python and have trouble printing data the way i want.
My container:
{
"id": "first",
"lexicon": {
"Eqt": "UNKN",
"PN": "abvcfgg",
},
"location": {
"Region": "China",
"Country": "China"
}
}
Python code:
for item in list(results):
print(results)
The output is:
{'id': 'test', 'lexicon': {'Eqt': 'UNKN', 'PN': 'abvcfgg'}, "location": { "Region": "China",
"Country": "China"}
The way output I want is:
id: test
Lexicon:
Eqt: UNKN
PN: abvcfgg
location
Region: China
Country: China