Ticket #84: blogroll_postgres.patch
| File blogroll_postgres.patch, 0.9 kB (added by scsibug, 6 months ago) |
|---|
-
a/apps/blogroll/templatetags/blogroll_extras.py
old new 17 17 """ 18 18 query = """ 19 19 SELECT %(link)s.id FROM %(link)s 20 LEFT JOIN %(comment)s on %(comment)s.user_id=%(link)s.user_id 21 GROUP BY %(link)s.id 22 ORDER BY %(comment)s.upd_date DESC LIMIT %(limit)d""" % { 20 ORDER BY %(link)s.order""" % { 23 21 'link': qn(Link._meta.db_table), 24 'comment': qn(CommentNode._meta.db_table),25 'limit': 526 22 } 27 23 cursor = connection.cursor() 28 24 cursor.execute(query)
