drop quoting group by

This commit is contained in:
Bartosz Wiśniewski 2020-07-22 19:02:38 +02:00
parent ebdadb3aee
commit 10159b61bf

View File

@ -387,7 +387,7 @@ class QuerySet(object):
sql += '\nWHERE ' + self.conditions_as_sql(prewhere=False) sql += '\nWHERE ' + self.conditions_as_sql(prewhere=False)
if self._grouping_fields: if self._grouping_fields:
sql += '\nGROUP BY %s' % comma_join('`%s`' % field for field in self._grouping_fields) sql += '\nGROUP BY %s' % comma_join('%s' % field for field in self._grouping_fields)
if self._grouping_with_totals: if self._grouping_with_totals:
sql += ' WITH TOTALS' sql += ' WITH TOTALS'