Thanks for your help, Elliot! I was able to write the SQL command:
UPDATE wp_postmeta SET meta_value = 'No' WHERE meta_key = 'block';
But the problem is, that meta_key doesn’t exist in the database until a value is saved within the custom post type. I think the reason is because I switched the field from a True/False field to a Radio Field.
Check out these screenshots:
File 1: This shows the missing value for the custom post type that I want to update via phpMyAdmin (remember, there are 100+ of these). Right above it, the value exists because I edited the cpt and re-saved it.
File 2: This shows the that field exists in the database for ‘alfr’ (as shown in File 1)
File 3: This shows that the field doesn’t exist in the database for ‘all-2’ (as shown in File 1).
Since the database has no record of it, I can’t use my UPDATE command.
Thoughts?
I wouldn’t say the site’s running a lot of theme functions — pretty generic stuff in my opinion. And the only plugin operating is your ACF + repeater and a shortcode plugin.
I thought I did try the relationship field and was still getting the error, but as of right now, I cannot remember.
Consider this forum posting solved or moot (for lack of a better term).
Looking forward to v.5, Elliot. Keep up the good work!
🙂
Later in the day, I found that I was able to make a 2nd repeater with Title, Text, and Image fields. For whatever reason, using the repeater field with Post Object or Relationship is a no go.
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.