On 25 Sty, 07:38, Kenneth Gonsalves <[email protected]> wrote: > hi, > > I have a model 'Player' and a Model 'Handicap'. Handicap will have several > fields, one of which is a foreign key to player. Now I need to get the > Handicap > instance when the player had the highest handicap. I can use Max to find the > highest handicap and do a query to identify the instance where the handicap is > at Max value. Is there a simpler way of doing this? >
I'm not sure if I understand correctly, but you are probably asking for something like this: http://groups.google.pl/group/django-users/browse_thread/thread/3b3cd4cbad478d34/3e4c87f336696054?hl=pl&q= http://stackoverflow.com/questions/2074514/django-query-that-get-most-recent-objects-from-different-categories/2076665 -- Tomasz Zielinski http://pyconsultant.eu -- 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.

