Once again, thanks all for the help, I really do appreciate it. Karen, I've read that page at least 10 times in the past 24 hours. Perhaps I just don't understand it though. The problem is that using "filter" returns a queryset which does not contain the *_set function that using "get" supplies. The only function the queryset provides, that I thought by the name of it would work, is you guessed it, select_related. This seems to be close to what I need but I can't figure out how to use it properly.
http://docs.djangoproject.com/en/dev/topics/db/queries/#queries-over-related-objects Malcom, the problem is that those results are not available. I opened up the shell and produced this little snippet so that you can see what I'm seeing... >>> t = Torrent.objects.filter(name__icontains='x360') >>> dir(t) ['__and__', '__class__', '__delattr__', '__dict__', '__doc__', '__getattribute__', '__getitem__', '__getstate__', '__hash__', '__init__', '__iter__', '__len__', '__module__', '__new__', '__nonzero__', '__or__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__str__', '__weakref__', '_clone', '_fill_cache', '_filter_or_exclude', '_iter', '_merge_sanity_check', '_next_is_sticky', '_result_cache', '_result_iter', '_sticky_filter', '_update', 'all', 'as_sql', 'complex_filter', 'count', 'create', 'dates', 'delete', 'distinct', 'dup_select_related', 'exclude', 'extra', 'filter', 'get', 'get_or_create', 'in_bulk', 'iterator', 'latest', 'model', 'none', 'order_by', 'query', 'reverse', 'select_related', 'update', 'value_annotation', 'values', 'values_list'] Perhaps one of those objects contains just the function I need but I'm not sure. If I use "get" and specify an id to lookup it provides the neccesary *_set objects (torrentinfo_set, torrenttrackers_set) and I can use those to access the related data but since I'm building a search engine of sorts I have to use filter as I don't know which id someone would be looking for. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---