Bulk edit ACF fields of WooCommerce products: dates, checkboxes
To bulk edit ACF fields of WooCommerce products, you do not need a special integration: Advanced Custom Fields saves every value of a product as post meta under the field name, and BEAR edits post meta as table columns. What you do need is to know how ACF stores each field type, because BEAR writes exactly the value you give it. A date in the wrong format, a checkbox saved as plain text or a missing reference key is why a value can look right in BEAR and still not appear on the product page. Below is how to attach each field type correctly, how to edit checkbox lists, and what to check when a value does not show up.
How ACF stores a product field
For a field named release_date, ACF writes two meta keys on the product when you save it in the product editor:
release_dateholds the value._release_dateholds the field key, a code such asfield_64f0c2a1b7e3d. This reference tells ACF which field definition the value belongs to.
BEAR edits the first key. The reference already exists on every product that was saved in the product editor while the field group was assigned to it. Products that were imported, or that got the value from BEAR before anyone saved them with the field group, have the value but no reference. That difference explains most values that do not show up, as described below.
Always attach the field name, not the label shown above the field and not the field key. The name is the Field Name in the ACF field group settings.
Add an ACF field as a column
- Fill in the field on one product in the product editor and save it.
- In BEAR's Meta Fields tab enter that product's ID in Get meta keys from any product by its ID and press Get. The list shows both
release_dateand_release_date; keep the one without the underscore. You can also type the name into Add Custom key by hands. - Give the field a short title, choose the view and type from the table below, and press Save meta fields.
- Switch the new column on in the Settings tab and save. Only then does the field appear in the Filters and Bulk Edit tabs.
The Meta Fields documentation describes the tab in detail.
Bulk edit ACF fields by field type
| ACF field type | Stored value | View and type in BEAR |
|---|---|---|
| Text, Text Area, Email, URL | The text | textinput or textarea, string |
| Number, Range | The number | textinput, number |
| True / False | 1 or 0 | checkbox |
| Radio Button, Button Group, Select (one value) | The value of the chosen choice, not its label | textinput, string |
| Checkbox, Select (multiple values) | A serialized list of choice values | textinput, string, plus the save code below |
| Date Picker | 20261231 (Ymd) | textinput, string or number, never calendar |
| Date Time Picker | 2026-12-31 18:00:00 | textinput, string |
| Image, File | The attachment ID | textinput, number |
| Group | Each sub-field under groupname_subfieldname | Attach each sub-field separately |
| Repeater | The row count under the name, rows under name_0_subfield, name_1_subfield | See bulk editing ACF repeater fields |
Dates show 1970
BEAR's calendar view is built for dates stored as a Unix timestamp, a count of seconds. ACF's Date Picker saves 20261231 whatever display format you chose in the field settings; read as seconds, that number is a day in August 1970, which is what the calendar cell shows (a Date Time Picker value turns into 1 January 1970). Picking a date in that cell would save a timestamp, so the field would end up holding dates in two formats, and anything that sorts or compares it, such as a query for upcoming dates, would treat them wrongly.
Attach ACF dates with the view textinput and type them the way ACF stores them: 20261231. With the type number the column also sorts by date and filters by a from/to range, for example 20261201 to 20261231 for December. A Date Time Picker field needs the full 2026-12-31 18:00:00 as a string.
True/False and fields with two choices
A True / False field stores 1 or 0, which is exactly what BEAR's checkbox view writes, so the table cell works without anything else. One exception in BEAR 2.2.4: in the Bulk Edit tab, choosing No for a checkbox field saves the value 2, which ACF reads as true. To switch such a field off on many products, change its view in the Meta Fields tab to textinput with the type number for a moment, set it to 0 in the Bulk Edit tab, and switch the view back to checkbox. Bulk Yes works as expected. A radio field with two choices, such as in_season and out_of_season, can use the checkbox too: in the Settings tab, under General settings, fill in Override meta checkbox value with season_status:in_season^out_of_season. A ticked checkbox then saves the first value and an unticked one the second; separate several fields with commas. Fields with more choices use a string field where you type the choice value.
Checkbox and multi-select fields
ACF saves a checkbox list as a serialized array, while a BEAR text field saves text. Type the choice values separated by commas, for example pdf, epub, print, and add a save handler that turns the text into the array ACF expects. The FAQ on ACF select and multi-select fields shows the basic version; the one below also stores a single choice as a list, as ACF does, and writes the reference key.
/*
* BEAR + ACF: save comma-separated choices typed in BEAR as the array used by
* ACF checkbox and multi-select fields, and write the ACF field reference.
* Child theme functions.php or a code snippets plugin.
* List each field as 'field_name' => 'ACF field key'.
*/
add_filter('update_post_metadata', function ($check, $object_id, $meta_key, $meta_value) {
$acf_list_fields = array(
'product_formats' => 'field_64f0c2a1b7e3d',
);
if (!isset($acf_list_fields[$meta_key]) || !is_string($meta_value) || '' === trim($meta_value)) {
return $check;
}
$choices = array_values(array_filter(array_map('trim', explode(',', $meta_value)), 'strlen'));
update_post_meta($object_id, $meta_key, $choices);
update_post_meta($object_id, '_' . $meta_key, $acf_list_fields[$meta_key]);
return true;
}, 10, 4);
ACF itself saves arrays, not text, so the handler leaves the product editor alone, and an emptied cell is saved as empty. If you already use the FAQ version for a field, replace it with this one rather than running both. Use the choice values, not the labels. In the Bulk Edit tab use new: append and prepend add text to the stored list and do not work for these fields.
To find the field key, attach _product_formats as a string field for a moment: on products saved in the product editor its column shows the field_ code.
The value is saved but not shown on the product page
When BEAR shows the new value and the product page does not, check these causes in order.
- The format. Compare the stored value with the table above: a select saved with its label instead of its value, or a checkbox list saved as plain text, does not match any of the field's choices, and a date saved as a timestamp is not in the format ACF writes.
- The reference. Products without the
_fieldnamekey still have the value, and ACF'sget_field()can usually find the field by its name. Code that relies on the reference may not recognise the value; filter and search plugins that read ACF fields, such as FacetWP, are the typical case. You can add the reference without code. Attach_release_dateas a string field, read the field key on a product saved in the editor, then in the Bulk Edit tab set it with new for all products that use the field. The key is the same for every product. - Caches and indexes. Clear the page cache and any object cache. After each change BEAR runs the usual
save_postandwoocommerce_update_productactions, which most indexing plugins listen to; if a filter plugin such as FacetWP still shows old data, run its re-index once.
Repeaters have references for the repeater and for each sub-field row, which is why a repeater edited only in its sub-field keys often appears on the front end only after the product is saved by hand. The repeater FAQ linked above solves it with ACF's own update_field().
ACF fields on variations
ACF's own location rules do not place field groups on product variations; add-ons that do so save the values as meta of each variation. Enter a variation ID in Get meta keys from any product by its ID to see their keys, attach them like any other field, and switch on variations on the tools panel to edit them. Text and number rows of the Bulk Edit tab then write to the variations. Two limits apply in that mode: meta field filters look at the parent products, and fields with the checkbox view are not offered in the Bulk Edit tab.
Before a bulk run on ACF fields
- The field is attached by its name, with the view and type from the table.
- Dates are typed as
20261231, never picked in a calendar cell. - Checkbox and multi-select fields have the save handler, and runs use new.
- Products created outside the product editor have the
_fieldnamereference. - A test on two products shows the value on the product page; a wrong run can be reverted in the History tab.
If an ACF field type is not covered here, post the field type and a product ID on the BEAR support forum.