summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
Diffstat (limited to 'modules')
-rw-r--r--modules/comment/comment.install1
-rw-r--r--modules/system/system.install9
2 files changed, 10 insertions, 0 deletions
diff --git a/modules/comment/comment.install b/modules/comment/comment.install
index 45afd76bd..780753c75 100644
--- a/modules/comment/comment.install
+++ b/modules/comment/comment.install
@@ -287,6 +287,7 @@ function comment_schema() {
'primary key' => array('nid'),
'indexes' => array(
'node_comment_timestamp' => array('last_comment_timestamp'),
+ 'comment_count' => array('comment_count'),
),
'foreign keys' => array(
'nid' => array('node' => 'nid'),
diff --git a/modules/system/system.install b/modules/system/system.install
index 20f35d549..a21d9f503 100644
--- a/modules/system/system.install
+++ b/modules/system/system.install
@@ -2257,6 +2257,15 @@ function system_update_7029() {
}
/**
+ * Add an index to node_comment_statistics on comment_count.
+ */
+function system_update_7030() {
+ $ret = array();
+ db_add_index($ret, 'node_comment_statistics', 'comment_count', array('comment_count'));
+ return $ret;
+}
+
+/**
* @} End of "defgroup updates-6.x-to-7.x"
* The next series of updates should start at 8000.
*/