Depending on whether or not your member and product tables are changed often, the MySQL Query Cache might be an interesting feature for you.
It caches the result sets for queries once they are processed and delivers them from the cache for some time. You can set the refresh time to a longer span, if your tables change less often, so you will benefit from the cached results for longer.
Refreshes to the cache could then be done by a script which is triggered from a Cronjob or something else. I use something similar to create full page cache versions of a website and only refresh the cache every hour or so.
StackOverflow has some interesting questions on this topic, too. You might start here: PHP Best way to cache MySQL results?
Related Posts:
- Use REGEXP in WP_Query meta_query key
- Query all posts where meta value is empty
- Meta Query with date and time on the same Day before given time
- Order By Multiple Meta Fields
- Using WP_Query and WP_Meta_Query Outside of WordPress
- Single meta_query query using OR instead of AND in request’s WHERE statement
- Performance when getting post meta for post retrieved by meta value
- Mysql query and order meta value
- Help with WP_Query – Too many mySQL queries
- Meta Query doesn’t works as espected
- meta_query: check if number exists
- How I can change the condition or compare operator for WP_Query in pre_get_posts
- Check if searched number is within the post meta value
- How to add date_query to meta_query array
- get_posts query is taking about 40 seconds to execute
- WP Query – grouping posts by same meta key, adding together values from another key
- Woocommerce Get Orders By Meta Value
- WordPress Query optimaization for slow query
- Order Posts By Custom Field That is an array of objects
- Use not custom fields in get_posts() meta_query?
- WordPress extremely slow when using get_posts with multiple meta_query relations
- When should you use WP_Query vs query_posts() vs get_posts()?
- When to use WP_query(), query_posts() and pre_get_posts
- Meta_query compare operator explanation
- meta_query with meta values as serialize arrays
- Nested meta_query with multiple relation keys
- meta_query ‘compare’ => ‘IN’ not working
- Return only Count from a wp_query request?
- WP Query Args – Title or Meta Value
- Meta query with string starting like pattern
- compare meta_query in get_posts arguments
- How to query posts based on lat-lng coordinate as post meta?
- How to use the_posts_navigation for wp_query and get_posts?
- WP_Query vs get_posts
- how to show posts that are missing a meta_value
- Set Alias for meta_query arguments in get_posts()
- Sorting: custom query with orderby meta_value_num THEN by title
- Order by DESC, ASC in custom WP_Query
- How to prevent execution of default query, while preserving ability to use WP_Query in template?
- meta_query: using BETWEEN with floats and/or casting to DECIMAL
- Get posts from Network (Multisite)
- Display products from specific category in shop page
- How to order by post_status?
- Using get_posts vs. WP_Query
- Delete all posts from WordPress except latest X posts
- How to Compare Two Meta Fields
- Changing the meta_query of the main query based on custom query_vars and using pre_get_posts
- Sanitation needed for WP_Query or get_posts calls?
- Differences Between WP_Query() and get_posts() for Querying Posts?
- Does tax_query really beats meta_query in all situations?
- WP_Query with checkbox meta_query
- ACF Relationship Field Search Filtering [closed]
- Add indexing to meta_value in wp_postmeta
- Get Recent Posts by Date in Multisite
- Is it possible to orderby multiple meta_keys when using meta_value_num?
- Custom WP_Query order by post_meta and (author) user_meta
- get_posts with multiple categories
- Query WooCommerce orders where meta data does not exist
- get_template_part in for loop
- Use of caller_ get_ posts
- Getting attachments by meta value
- Query Multiple Post types each with own meta query
- How-to exclude terms from the main query the most performant way?
- Get posts by menu ID
- Execute a large WP_Query with many “AND” Meta_Queries?
- Is it possible to select against a post’s parent’s fields with WP_Query?
- WP_Query min and max values
- Slow SQL_CALC_FOUND_ROWS Query
- Get posts by meta data OR title
- ACF datepicker meta_query Compare Dates in m/d/Y g:i a – Not in Ymd Format
- WP_Query using meta_query with relation OR and orderby meta_value doesn’t work
- Using custom meta_query with relation not working as expected
- Get_post() with meta_key when compare is a date
- Perform query with meta_value date
- get_posts not finding argument: post_name
- querying with custom meta field with meta_query
- Order by two meta keys
- multiple meta key but get server load is very high
- A WP_Query that will look for posts after 2 weeks ago OR with a certain meta value
- How to grab metabox value in wp_query meta_query key
- WP_Query meta_query where meta value ends in space
- Get posts with condition on comment meta value
- Order by meta_value_num DESC and meta_value ASC on WP 4.0
- Finding all results from database within 500 miles of the given latitude and longitude [closed]
- Nested query inside Logical operator OR not working in meta_query
- Is “orderby” in WP Meta Query conflicting with Meta Query?
- Query by meta_key and order by meta_value_num return orderby date
- What is an efficient way to query based on post_meta?
- WP_Query not working as expected for attachments and custom meta_query
- SQL query equivalent to WP User Query
- Function to check if author has posted within the last x days
- datetime picker, timestamps and meta queries
- How do I create my own nested meta_query using posts_where / posts_join?
- What’s wrong with this WP query?
- Stop all SQL_CALC_FOUND_ROWS wordpress queries
- How to count post meta key values for all posts in database
- Use post__in and post__not_in together?
- WooCommerce: filter by parent product’s taxonomy and product variation’s meta data
- How to order a post type with meta_value_num and if meta_value_num does not exist then order by date
- Group posts by meta_key