->
fields('i18n'
) ->
fields('lt',
[ 'translation',
'language',
'plid',
'plural',
]) ->
condition('i18n.type', 'field'
) ->
condition('property', 'option\_%', 'LIKE'
);
$query->
innerJoin('locales_target', 'lt', '[lt].[lid] = [i18n].[lid]'
);
$query->
leftjoin('content_node_field', 'cnf', '[cnf].[field_name] = [i18n].[objectid]'
);
$query->
addField('cnf', 'field_name'
);
$query->
addField('cnf', 'global_settings'
);
// Minimise changes to the d6_field_option_translation.yml, which is copied
// from d6_field.yml, by ensuring the 'type' property is from
// content_node_field table.
$query->
addField('cnf', 'type'
);
$query->
addField('i18n', 'type', 'i18n_type'
);
// The i18n_string module adds a status column to locale_target. It was
// originally 'status' in a later revision it was named 'i18n_status'.
/** @var \Drupal\Core\Database\Schema $db */
if ($this->
getDatabase()->
schema()->
fieldExists('locales_target', 'status'
)) {