Note: Only read briefly, so I might missunderstood your Q.
JOIN
on meta_query
/post_meta table is pretty … hm, funny(?) … as you’ll JOIN
the table (again) for every key you add – this is a known problem (read on trac). In detail INNER JOIN wp_postmeta ON (wp_posts.ID = wp_postmeta.post_id)
is the same as INNER JOIN wp_postmeta AS mt1 ON (wp_posts.ID = mt1.post_id)
. And ORDER BY wp_postmeta.meta_value ASC
is the same as ORDER BY mt1.meta_value ASC
.
You could try using the posts_clauses
or posts_orderby
filter to change the ORDER BY
statement:
function wpse_change_orderby( $orderby )
{
return 'ORDER BY DATE ASC';
}
add_filter( 'posts_orderby', 'wpse_change_orderby' );