On Aug 15, 9:42 pm, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
>
> It's not completely clear to me whether this is a bug or not, although
> enough people think it's counter-intuitive that it might be worth
> changing. The problem is that both answers are correct, depending on
> your interpretation of how author__name should be interpreted (which is
> a subtle issue, so it's easy for somebody to think the answer is obvious
> and should "obviously" be the way they see it, but it genuinely is a
> two-sided issue).
>
> The issue at work is that the Author class has no link to Article Two at
> all (since that article has no author). So, on the SQL level, it doesn't
> really make sense to query the authors table for things involving
> article two -- because article two is invisible to the authors; no
> linkage. However, it seems a lot of people would like author__name to be
> a way of transparently moving through the relationship as a formal
> matter, regardless of whether there's any actual data linkage or not and
> only then apply the filter to the field we end up in.
>
> I'm semi-convinced by this argument, so in the QuerySet rewrite I'm
> doing, I'm making the latter situation be the "correct" answer. By the
> way, this is ticket #2080 (marked as a dupe of #1801, but #2080 is
> probably the clearer explanation of the issue).
>
Thanks for your considered response. Where I actually hit this issue
was using stuff.search in one of my apps and it uses Or-ed Q()'s to
generate the search query across multiple fields in a model. My users
noticed that some of their searches weren't returning complete result
sets. So in my user's situation they aren't getting the "correct"
answer. I also noticed that #2080 is closed. If #1801 being open
sufficient for this issue to be tracked?
> Regards,
> Malcolm
>
> --
> Despite the cost of living, have you noticed how popular it
> remains?http://www.pointy-stick.com/blog/
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---