Query by empty JsonField in django
Try MyModel.objects.filter(myjsonfield='[]').
I need to query a model by a JsonField, I want to get all records that have empty value ([]):
I used MyModel.objects.filter(myjsonfield=[]) but it's not working, it returns 0 result though there's records having myjsonfield=[]