I have entries from the different users, they're entering the total number of steps they walked during a particular period of time, that they set.
So the model is setup like user (fk) start_date = DateField() end_date = DateField() steps = IntergerField() What I want to do is on the user's detail page to sum all the entries in the db for that model where user = page_user. I know with SQL you can do a query and just SUM(steps) as total_steps WHERE user = get_user. Is there a way, better/preferred, to do it with Django? Also, on the site's front page, I'd like to list the top 10 total as well. --~--~---------~--~----~------------~-------~--~----~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---