[wp-trac] [WordPress Trac] #43636: Additional wp_query 'fields' choices
    WordPress Trac 
    noreply at wordpress.org
       
    Mon Mar 26 19:54:40 UTC 2018
    
    
  
#43636: Additional wp_query 'fields' choices
-------------------------+-----------------------------
 Reporter:  mattkeys     |      Owner:
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  Query        |    Version:  4.9.5
 Severity:  normal       |   Keywords:
  Focuses:  performance  |
-------------------------+-----------------------------
 Currently wp_query accepts an option called 'fields' with possible values
 of: ids or id=>parent.
 I propose that two new options be added: author_ids, titles.
 My current use case is that I am needing to populate a list of all author
 ids that meet certain post type and taxonomy parameters. I only need the
 author ids and would like to exclude querying all of the fields for
 performance reasons.
 Looking through the wp_posts table the only other column that I think
 there is a good use case for is the post_title column.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/43636>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
    
    
More information about the wp-trac
mailing list