python - Query by empty JsonField in django -


i need query model jsonfield, want records have empty value ([]):

i used mymodel.objects.filter(myjsonfield=[]) it's not working, returns 0 result though there's records having myjsonfield=[]

try mymodel.objects.filter(myjsonfield='[]').


Comments

Popular posts from this blog

python - No exponential form of the z-axis in matplotlib-3D-plots -

python - PIL cannot identify image file for io.BytesIO object -

java - disabling a node without disable its children in javafx -