I am using mongodb(3.6)
in python(3.8.5)
django(3.1.5)
. and i have used djonjo(1.3.3)
for mongodb connection.
when i have run aggregate query with
model.objects.aggregate({'$graphLookup': {
'from': 'categories_categories',
'startWith': 'id',
'connectFromField': 'sub_category',
'as': 'SubCategory'
}
})
so i am getting error :
`QuerySet.aggregate() received non-expression(s): {'$graphLookup': {'from': 'categories_categories', 'startWith': 'id', 'connectFromField': 'sub_category', 'as': 'SubCategory'}}.`
question from:https://stackoverflow.com/questions/65661884/djongo-aggregate-in-python-django