When running migrations with wp_term source, there is an error:

Migration failed with source plugin exception: SQLSTATE[23000]: Integrity constraint violation: 1052 Column 'term_id' in on clause is ambiguous: SELECT t.term_id AS term_id, t.name AS    [error]
name, t.slug AS slug, tt.taxonomy AS taxonomy, tt.description AS description, map.sourceid1 AS migrate_map_sourceid1, map.source_row_status AS migrate_map_source_row_status
FROM
{terms} t
INNER JOIN {term_taxonomy} tt ON tt.term_id = t.term_id
LEFT OUTER JOIN drupal.migrate_map_pt_categories map ON term_id = map.sourceid1
WHERE (tt.taxonomy IN (:db_condition_placeholder_0)) AND ((map.sourceid1 IS NULL) OR (map.source_row_status = :db_condition_placeholder_1))
ORDER BY t.term_id ASC; Array
(
    [:db_condition_placeholder_0] => category
    [:db_condition_placeholder_1] => 1
)

The problem is that there is no alias on the map table. This has to be fixed.

Comments

hussainweb created an issue. See original summary.

  • hussainweb committed 5dde9b1 on 8.x-1.x
    Issue #2909994 by hussainweb: Integrity constraint violation when...
hussainweb’s picture

Status: Needs work » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.