The question was for WordPress 3.0, but just in case someone has the same question for a more recent version, from WordPress Codex:
“Starting with version 4.1, meta_query clauses can be nested in order to construct complex queries.”
https://developer.wordpress.org/reference/classes/wp_query/#custom-field-post-meta-parameters
So, that query should work on the current WordPress version.
Related Posts:
- Does tax_query really beats meta_query in all situations?
- Query Multiple Post types each with own meta query
- Perform query with meta_value date
- Meta Query with date and time on the same Day before given time
- search query within custom taxonomy term, post title and meta field
- How do I create my own nested meta_query using posts_where / posts_join?
- WooCommerce: filter by parent product’s taxonomy and product variation’s meta data
- Querying by taxonomy vs Querying by Custom fields Speed Comparison
- How to query ‘posts_per_page’ to display a different blog posts index template?
- Order a query result by a numeric meta key even if it does not exist, but put the posts with meta key first
- WP_Query last five posts, simply ordered by meta_value
- Tax query clause inside a meta query clause?
- Fetch Record based on meta key dates
- How to display multiple custom fields with the same meta_key in an ascending order?
- Is it a good idea to improve meta query performance by adding tax query?
- how to make members list directory through wordpress post custom meta key.
- Tax query AND/OR meta query [duplicate]
- Query with meta_query and tax_query together not working properly
- How to provide meta_key array to wp_query?
- How to search for meta_query LIKE or tax_query LIKE and grab these posts on search results?
- Is it possible to add relation between meta_query and tax_query?
- Show single posts date, in a page of posts
- meta_query with array as value with multiple arrays
- Why doesn’t my WP Meta Query return any results?
- WP_Query Class custom field parameters
- Magazine style frontpage with multiple categories/loops and no duplicate posts
- Facing problem with tax_query results
- How do i create a custom post query when the meta value is an array?
- ElasticPress is (aparently) messing with my search filters
- WP_Query for a taxonomy value OR a custom post type meta field
- Query for current post
- Custom query to retrieve oldest post and retrieve others with date interval
- Orderby query does not work for custom fields even with meta query
- Custom WP_query and integrating into theme file
- Extending WP Query: Custom geolocation meta values work, but tax_query breaks
- query post based on comparison
- WP Query – Show custom posts only if user contain some user meta
- Custom query with custom filtering returning incorrect results
- How to query for most viewed posts and show top 5
- Escaping WP_Query tax_query when term has special character(s)
- Is there an action/filter called when WP_Query->query is finished and assigns posts
- get_the_title($postID) OR get_the_title()?
- datetime picker, timestamps and meta queries
- Compare two meta-fields in a wp_query (where meta-field-A is larger than meta-field-B)
- Meta Query querrying several post types based on ACF fields is broken after update to WP 4.1
- How to get sum of meta_values of a meta_key in wp_query according to conditions
- tax_query shows no results if nothing is selected
- meta_key and meta_value not working together
- how to speed up a complex wp_query?
- How to query for custom field within Gutenberg block from outside of that post? [closed]
- Multiple instances of Featured Image Query
- Meta Query for specific months
- Meta query with JSON value
- Get meta info related to current post
- ACF Date Based wp_query
- Get attachment by meta_key value
- Using meta_query with multiple keys and compare values
- How to optimize multiple WP_Query() calls on one page?
- Mysql query and order meta value
- Bypass “supress_filters” in WP Query
- meta_query BETWEEN, but the range is stored in the custom field
- Order ascending is ignored in meta query?
- database query with more than a couple meta hangs and doesn’t complete
- Finding WordPress Posts assigned to multiple categories
- Conditional operator OR not working with custom fields
- Should I reset $wp_query?
- Sort by presence of thumbnail
- Get posts in taxonomy randomly
- it’s possible make a WP_Query with math operations?
- Sorting search results with custom dropdown
- Posts query according to meta box date
- Max Posts and Memory Limit
- What’s missing in this wp_query and meta_query
- Query post and sort by custom value calculated with custom field on cpt
- Any quicker alternative for WP_Query “NOT IN”
- Tax Query on product_cat using NOT IN as operator does not exclude that category
- ACF: How to query for a given value count of an array like field? (e.g.: How many rows has a `flexible_content` field?)
- custom post type and a “sticky” position taxonomy
- Trouble with serialized metadata
- meta_query order by date present -> future then show null
- Problem with my loops
- Multi line of $wpdb->query just run 1 time and end the loop right after
- meta_query compare > not working
- How to add in WP_Query to every 3 posts displayed? [duplicate]
- Saving custom fields for WP_Query to retrieve
- In Product Category archives how to show Posts having same/similar prod_cat slug structure?
- Modify query to exclude certain ids and certain parents and its corresponding children
- Filter posts/pages by user_role array
- WP_Query with MetaQuery issue
- WP_Query with meta_value_num and meta_query not paged correctly
- Post Query not working after updating to 4.1
- The sorting of posts by a meta_query with two keys fails while separated as single queries it works
- Sort Posts with custom meta key by default which is currently set as optional
- WP_Query with several meta_query-statements and order by meta_value
- WP_Query breaks pagination
- Pagination problem with multiple loops on the same page
- Output ACF field dynamicaly within a taxonomy loop [closed]
- Incorrect posts displayed on category page
- How do I have multiple metaqueries inside one wordpress query
- Display only posts with thumbnails