When I define a field with taxonomy term fields, I can set a default value depending on the available terms. Since the terms themselves are content, they are not stored via configuration management. When I export the configuration on one server (e.g. development) and import it into a different server (e.g. stage), these values may differ. Especially two terms with the same value on the servers don't necessarily share the same tid.

When I set a default value in dev, then this value's tid maybe not be the same as on the stage server and thus no default value or a wrong default value might be chosen, if I insert a new content of the type that has that field.

How do I manage this?

1 Answer 1


I figured out the solution.

The value stored in the config/sync is not the tid of the taxonomy term, but the uuid. Because of this, I can just change the value of uuid column in taxonomy_term_data row of the dev's term to that of the stage's server without affecting the tid column.

  • Something like Content Serialization might help with exporting the taxonomy terms and preserve their UUID's. You shouldn't need to hand update the UUID's then I think.
    – Beebee
    Commented Mar 5, 2020 at 11:27
  • This project is not covered by Drupal’s security advisory policy.
    – yunzen
    Commented Mar 5, 2020 at 12:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.