diff gpp/forums/models.py @ 393:9af6bd45c1f8

Another try at #191 after getting some good advice in a django-users thread.
author Brian Neal <bgneal@gmail.com>
date Thu, 24 Mar 2011 00:15:34 +0000
parents b15726767ab8
children 42a4e66972d5
line wrap: on
line diff
--- a/gpp/forums/models.py	Wed Mar 23 02:02:44 2011 +0000
+++ b/gpp/forums/models.py	Thu Mar 24 00:15:34 2011 +0000
@@ -202,7 +202,7 @@
 
     # denormalized fields to reduce database hits
     post_count = models.IntegerField(blank=True, default=0)
-    update_date = models.DateTimeField()
+    update_date = models.DateTimeField(db_index=True)
     last_post = models.OneToOneField('Post', blank=True, null=True,
         related_name='parent_topic')