Home › Forums › ACF PRO › Performance issues with hundreds of queries › Reply To: Performance issues with hundreds of queries
It’s quite possible, you should probably do some testing, but, my understanding is that if you use get_post_meta($post_id)
without specifying a meta_key
that WP gets all of the meta values for a post in a single query. WP also caches the results of this in a non-persistent cache so that the next time the function is called it uses values it already has. The ACF get_field()
and other functions are just wrappers for get_post_meta()
and get_option()
.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.