Hi all,

I'm using contrib.auth and have set up my own Profile model, linked to
the User model with OneToOneField. There are a lot of times when I'd
like to prefetch the Profile model when getting the User model -- e.g.
User.objects.all().select_related('profile')

However, select_related does not seem to follow the OneToOneField back
to the User though. It appears to be a one-way relationship. Does
anyone have any ideas on how to make this happen short of directly
modifying the User model in contrib.auth?

-- Andrew
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to