public function Sql::prepareUpdate in Drupal 10
Same name and namespace in other branches
- 8 core/modules/migrate/src/Plugin/migrate/id_map/Sql.php \Drupal\migrate\Plugin\migrate\id_map\Sql::prepareUpdate()
- 9 core/modules/migrate/src/Plugin/migrate/id_map/Sql.php \Drupal\migrate\Plugin\migrate\id_map\Sql::prepareUpdate()
Prepares to run a full update.
Prepares this migration to run as an update - that is, in addition to un-migrated content (source records not in the map table) being imported, previously-migrated content will also be updated in place by marking all previously-imported content as ready to be re-imported.
Overrides MigrateIdMapInterface::prepareUpdate
File
- core/
modules/ migrate/ src/ Plugin/ migrate/ id_map/ Sql.php, line 745
Class
- Sql
- Defines the sql based ID map implementation.
Namespace
Drupal\migrate\Plugin\migrate\id_mapCode
public function prepareUpdate() {
$this
->getDatabase()
->update($this
->mapTableName())
->fields([
'source_row_status' => MigrateIdMapInterface::STATUS_NEEDS_UPDATE,
])
->execute();
}