Fixing metafield validation errors
After youmigrate existing metafields to a definition, you can use the bulk editor to fix any metafield values that don't match your custom definition. You're automatically redirected to the bulk editor on theInvalid metafield valuespage after you create a definition that has invalid values.
TheInvalid metafield valuespage displays the validation rules for your metafield definition and a table that contains the following information:
- the parts of your store that have an invalid value for your metafield definition
- a description of the error for each metafield value
- an editable column where you can enter new values for your metafields
If some of your metafield values are invalid, then you can't use your metafield until you fix all the errors. For more information about which values are valid for different metafields, refer tothe list of common metafield content types and values.
Fix metafield values by using the bulk editor
If you create a custom metafield definition that contains invalid values, then you're automatically redirected to the bulk editor to fix the validation errors.
Steps:
- Optional: Hover your cursor over the
i
icon next to a metafield value to view the error that's associated with it. - Click and type within fields in theMETAFIELD VALUEcolumn to edit the existing values. To update multiple values at the same time, use the following shortcuts:
- To select and edit multiple fields at the same time, click and drag your cursor across multiple cells.
- To select multiple adjacent cells, click to select a cell, then hold the
转变
key and click another cell. - To select multiple cells that aren't adjacent, hold the
Alt
key on a PC or thecommand
key on a Mac and click different cells. - To apply the value of a cell to the cells below it, click and drag the cell's fill handle across the cells below.
- ClickSave.
After you save your changes, the table of metafield values displays the following updated statuses:
- All metafield values that match your metafield definition display a checkmark.
- Any metafield values that still need to be fixed display the
i
icon.
If any metafield values still display errors, then repeat this process until all values are fixed. You can't use your metafield until all values match your metafield definition.
If you don't fix your invalid values right away, then metafield definitions with invalid values display aFixes needederror message on theMetafield definitionspage. You can clickView invalid metafieldsto return to the bulk editor.