Tech Insights
Django prefetch_related makes an extra query to pre-fill the related objects. If you use prefetch_related 3 times in the ...
Django prefetch_related makes an extra query to pre-fill the related objects. If you use prefetch_related 3 times in the same queryset Django ORM will hit the database 4 times to fetch all the results.
Shared by



