remove LOWER() in Order by clause for Post Meta. Allows MySQL to use the indexes properly. Props Denis-de-Bernardy. Fixes #11741

git-svn-id: http://svn.automattic.com/wordpress/trunk@13503 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
dd32 2010-02-28 13:15:54 +00:00
parent 9f1b20ba95
commit 83e11093ab
1 changed files with 3 additions and 3 deletions

View File

@ -2427,7 +2427,7 @@ function meta_form() {
FROM $wpdb->postmeta
GROUP BY meta_key
HAVING meta_key NOT LIKE '\_%'
ORDER BY LOWER(meta_key)
ORDER BY meta_key
LIMIT $limit" );
if ( $keys )
natcasesort($keys);
@ -3288,7 +3288,7 @@ function find_posts_div($found_action = '') {
<?php wp_nonce_field( 'find-posts', '_ajax_nonce', false ); ?>
<label class="screen-reader-text" for="find-posts-input"><?php _e( 'Search' ); ?></label>
<input type="text" id="find-posts-input" name="ps" value="" />
<input type="button" onclick="findPosts.send();" value="<?php esc_attr_e( 'Search' ); ?>" class="button" /><br />
<input type="button" onClick="findPosts.send();" value="<?php esc_attr_e( 'Search' ); ?>" class="button" /><br />
<input type="radio" name="find-posts-what" id="find-posts-posts" checked="checked" value="posts" />
<label for="find-posts-posts"><?php _e( 'Posts' ); ?></label>
@ -3298,7 +3298,7 @@ function find_posts_div($found_action = '') {
<div id="find-posts-response"></div>
</div>
<div class="find-box-buttons">
<input type="button" class="button alignleft" onclick="findPosts.close();" value="<?php esc_attr_e('Close'); ?>" />
<input type="button" class="button alignleft" onClick="findPosts.close();" value="<?php esc_attr_e('Close'); ?>" />
<input id="find-posts-submit" type="submit" class="button-primary alignright" value="<?php esc_attr_e('Select'); ?>" />
</div>
</div>