Development

Migrating Specific Fields in a D8 Migration

I recently needed a way to update the value of a single field of a D7 to D8 node migration.

The client was already updating the migrated content so I had to be careful with what I migrated.

The entity destination plugin has a wonderful configuration option that allows you to specify which fields you want to migrate. Search the code here forĀ overwrite_properties.

Here’s how I used this to ignore every field except two:

I tested this by editing a node’s title, subtitle, field_tax_groups, and field_tags values. I ran the migration and the edits were preserved on the title and subtitle fields as expected.

Leave a Reply

Your email address will not be published.