Skip to content

Commit

Permalink
[1.5.x] Fixed #20168 - Generalized a PostgreSQL specific database que…
Browse files Browse the repository at this point in the history
…ry in the docs.

Thanks Russ for the suggestion.

Backport of c119d0f from master
  • Loading branch information
timgraham committed Mar 31, 2013
1 parent 9998173 commit a825b19
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/topics/db/managers.txt
Expand Up @@ -70,8 +70,8 @@ returns a list of all ``OpinionPoll`` objects, each with an extra
SELECT p.id, p.question, p.poll_date, COUNT(*)
FROM polls_opinionpoll p, polls_response r
WHERE p.id = r.poll_id
GROUP BY 1, 2, 3
ORDER BY 3 DESC""")
GROUP BY p.id, p.question, p.poll_date
ORDER BY p.poll_date DESC""")
result_list = []
for row in cursor.fetchall():
p = self.model(id=row[0], question=row[1], poll_date=row[2])
Expand Down

0 comments on commit a825b19

Please sign in to comment.