diff --git a/src/wp-admin/includes/schema.php b/src/wp-admin/includes/schema.php
index 20853da..cd69016 100644
--- a/src/wp-admin/includes/schema.php
+++ b/src/wp-admin/includes/schema.php
@@ -119,7 +119,8 @@ CREATE TABLE $wpdb->comments (
 	KEY comment_approved_date_gmt (comment_approved,comment_date_gmt),
 	KEY comment_date_gmt (comment_date_gmt),
 	KEY comment_parent (comment_parent),
-	KEY comment_author_email (comment_author_email(10))
+	KEY comment_author_email (comment_author_email(10)),
+	KEY comment_type (comment_type)
 ) $charset_collate;
 CREATE TABLE $wpdb->links (
 	link_id bigint(20) unsigned NOT NULL auto_increment,
diff --git a/src/wp-admin/includes/upgrade.php b/src/wp-admin/includes/upgrade.php
index 0390110..864bda4 100644
--- a/src/wp-admin/includes/upgrade.php
+++ b/src/wp-admin/includes/upgrade.php
@@ -3196,6 +3196,12 @@ function maybe_disable_automattic_widgets() {
 			break;
 		}
 	}
+
+	// Upgrade versions prior to 4.7
+	if ( $wp_current_db_version < 37966 ) {
+		// Add index to wp_comments comment_type field
+		$wpdb->query( "ALTER TABLE {$wpdb->comments} DROP INDEX comment_type, ADD INDEX comment_type (comment_type)" );
+	}
 }
 
 /**
