Support

Account

Home Forums Backend Issues (wp-admin) ACF field changed; Update values in phpMyAdmin Reply To: ACF field changed; Update values in phpMyAdmin

  • 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?