Comments broke after upgrading to wordpress 2.5

I borked something when I upgraded to wordpress 2.5. Ofcourse things break down together once again:

1) The cute little “challenge” plugin stopped working in the sense it blocked all comments even when the “challenge” got properly solved (not just spam and stupid people).

2) After disabling the plugin I found that the admin interface couldn’t view comments anymore.

Thankfully the following error showed up in the apache2 logs:

WordPress database error Key 'comment_date_gmt' doesn't exist in table 'wp_comments' for query SELECT SQL_CALC_FOUND_ROWS * FROM wp_comments USE INDEX (comment_date_gmt) WHERE comment_approved != 'spam' ORDER BY comment_date_gmt DESC LIMIT 0, 25 made by _wp_get_comment_list, referer: http://dev.osso.nl/herman/blog/wp-admin/edit-comments.php?comment_status=approved

Apparently WordPress 2.5 expects an INDEX on comment_date_gmt, which was not there.

ALTER TABLE `wp_comments` ADD INDEX ( `comment_date_gmt` ) ;

Fixed the problem. Maybe a side effect of of continuosly upgrading wordpress (I would guess adding the index was missing in an upgrade script along the way). Else lets blame it without any proof on MySQL for losing data randomly.

So feel free to leave comments once again!

ps. If someone still has tips to show off virtualisation in Ubuntu on the desktop I would love to hear it. I was kind of hoping on some responses on my last post.

No related posts.

Leave a comment

1 Comments.

Leave a Reply


[ Ctrl + Enter ]