While attempting to re-import commerce product variations with the update option I got
Update existing 'commerce_product_variation' entity while changing the ID is not supported.
On digging around I found this was caused by my blindly following the commerce_migrate example migration "csv_example_product_variation.yml" in csv_example module which explicitly sets variation_id from the sku:
process:
variation_id:
plugin: skip_on_empty
source: sku
method: row
I deleted the variation_id process bit which then allowed it to be set (correctly) as an auto-increment field, and the problem went away.
Since the SKU is a text field and variation_id is integer I think this amounts to a bug in the example migration.
Comment | File | Size | Author |
---|---|---|---|
#2 | 3112727-2.patch | 809 bytes | quietone |
Comments
Comment #2
quietone CreditAttribution: quietone as a volunteer commented@hughworm, thank you for reporting this error.
Adding a comment to the file and commenting out that section should be sufficient
Comment #4
quietone CreditAttribution: quietone as a volunteer commentedComment #5
timlie CreditAttribution: timlie commentedI can confirm this fixes the update import.
Comment #6
quietone CreditAttribution: quietone as a volunteer commented@timlie, thanks!