2009/3/12 Malcolm Tredinnick <malc...@pointy-stick.com>: > Aah... sorry. Too quick on the draw, there. :-) > > This does what you're after: > > User.objects.filter(userprofile__friends=user) > > UserProfile.objects.filter(friends=user) is correct if you want the > respective UserProfile objects back, but it sounds like you want the > User objects, so you have to traverse the relation back to UserProfile > and then filter. > > Regards, > Malcolm
That's it! Thank you very much! --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---