i believe the way filters work (what martin referenced) is that you
have to explicitly say which weekday you care about.
what the op is looking for is a way to group by week day. ideally to
write something like MyTable.objects.values(created__week_day).annotate
(Count('id'))
however, this doesn't
You can limit your search by year, month or day.
See http://docs.djangoproject.com/en/dev/ref/models/querysets/#year
On Nov 20, 1:59 pm, Simon wrote:
> Hi all,
>
> I am sure this must be a real noob question as it's so easy to do in
> SQL.
> I am trying to replicate something like the following
Hi all,
I am sure this must be a real noob question as it's so easy to do in
SQL.
I am trying to replicate something like the following in Django:
SELECT DATE(created) AS created_day, COUNT(id) AS NumberOf FROM
my_table GROUP BY created_day
Effectively, all I want to do is a count grouped by
3 matches
Mail list logo