[bbDev] [688] trunk: indices for date columns.

Matt Mullenweg m at mullenweg.com
Sun Feb 11 18:39:06 GMT 2007


m at wordpress.org wrote:
> +  KEY forum_id (forum_id),
> +  KEY topic_time (topic_time)
> +  KEY topic_start_time (topic_start_time)

I'm skeptical of this.

MySQL can only use one index per table per query, so if any combination 
of those fields are used in queries for a true speed-up we should use a 
multi-field key. (Like we do in WP.)

-- 
Matt Mullenweg
  http://photomatt.net | http://wordpress.org
http://automattic.com | http://akismet.com


More information about the bbDev mailing list