Simon Willison’s Weblog

Subscribe

Why does Django still not have support for multiple joins?

9th May 2011

My answer to Why does Django still not have support for multiple joins? on Quora

I don’t fully understand the question, but if you’re talking about doing a single join across multiple tables the Django ORM handles that just fine. Let’s say you want to get every BlogEntry written by a User who belongs to the Group with the name “admins”:

entries = BlogEntry.objects.filter(author__group__name = ’admins’)