Debdut Goswami
Debdut Goswami

Reputation: 1379

Empty QuerySet in django-mysql JSONField

When I am executing

ModelName.objects.filter(firstName__contains="MyName")

it returns an empty queryset but when I am executing it's SQL equivalent in dbshell it is fetching the rows perfectly.

select * from AppName_ModelName where firstName like '%MyName%';

I have constructed the sql query as per the documentation

Upvotes: 1

Views: 120

Answers (0)

Related Questions