[wp-trac] [WordPress Trac] #12891: Advanced multi-taxonomy WP_Query()s

WordPress Trac wp-trac at lists.automattic.com
Wed Apr 21 19:47:47 UTC 2010


#12891: Advanced multi-taxonomy WP_Query()s
-----------------------------+----------------------------------------------
 Reporter:  markjaquith      |       Owner:  ryan                
     Type:  feature request  |      Status:  new                 
 Priority:  normal           |   Milestone:  3.1                 
Component:  Query            |     Version:  3.0                 
 Severity:  normal           |    Keywords:  taxonomies has-patch
-----------------------------+----------------------------------------------
Changes (by scribu):

  * keywords:  taxonomies => taxonomies has-patch


Comment:

 I've added two sample implementations:

 - eager.php: each function generates the SQL code as soon as it's called

 - lazy.php: each function creates a new object; the sql can be generated
 at a later point.

 The lazy parsing implementation would only be useful if it would first
 analyze all the clauses and then output optimized SQL.

 On that note, instead of
 wp_some_function_to_get_an_ID_from_ID_or_name_or_slug(), I think it would
 be better if wp_tax() accepted a third $field argument, to avoid doing
 extra queries.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/12891#comment:8>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list