I need to do something like this:
quito = queryset.get(lugar="Quito")
queryset.pop(quito)
But I get the error:
'QuerySet' object has no attribute 'pop'
How can I solve this?
'QuerySet' object has no attribute 'pop'
You can see the details about Queryset
You can try:
Yourmodel.objects.exclude(lugar="Quito")
to filter the queryset, more details here Retrieving objects¶
How about queryset.exclude(lugar="Quito")
?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With