Home › Forums › General Issues › Flush Unused Custom Fields › Reply To: Flush Unused Custom Fields
It seems that flushing by field group should be helpful and feasible. If there is a field group ID than all the data with that ID could be deleted.
Data is stored in the postmeta table. This data is associated with the post ID of the post the data is assocaited with. There is nothing in the way that WP is build to also to associate this content with the field group the field belongs to.
The number of queries that would be involve to track down and delete all data when a field is deleted would in all likelihood time out the process. I’m sure that the reason that a solution has not been is not because the developer does not want to provide a solution but because there isn’t a practical way to supply that solution working within the way that WP and the DB are built.
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 Cookie Policy. If you continue to use this site, you consent to our use of cookies.