diff options
| author | Russell Keith-Magee <russell@keith-magee.com> | 2009-02-16 12:38:11 +0000 |
|---|---|---|
| committer | Russell Keith-Magee <russell@keith-magee.com> | 2009-02-16 12:38:11 +0000 |
| commit | 2b1bb716ff7552bf9f98653c172a573c380e4798 (patch) | |
| tree | 0377aa4ab869a84ecdb06977c11bd6d71739da13 /django/db/models/sql/query.py | |
| parent | fb64ea78968714929a75514ecd55fb5af1093697 (diff) | |
Fixed #10248 -- Corrected handling of the GROUP BY clause when using a DateQuerySet. Thanks to Alex Gaynor for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@9839 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django/db/models/sql/query.py')
| -rw-r--r-- | django/db/models/sql/query.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/db/models/sql/query.py b/django/db/models/sql/query.py index f868347960..629afa29e7 100644 --- a/django/db/models/sql/query.py +++ b/django/db/models/sql/query.py @@ -389,7 +389,7 @@ class BaseQuery(object): # other than MySQL), then any fields mentioned in the # ordering clause needs to be in the group by clause. if not self.connection.features.allows_group_by_pk: - grouping.extend([col for col in ordering_group_by + grouping.extend([str(col) for col in ordering_group_by if col not in grouping]) else: ordering = self.connection.ops.force_no_ordering() |
