ubertheme / module-ubdatamigration

This is a module for Magento 2. This allow migrate data from Magento 1.x to Magento 2.x
https://www.ubertheme.com/magento-extensions-2-x/magento-2-data-migration-pro?utm_source=github&utm_medium=repo&utm_campaign=magento_migration_ce
48 stars 38 forks source link

step 7 error to migrate sales (Customer Taxvat is too long) #16

Closed developer-lindner closed 8 years ago

developer-lindner commented 8 years ago

Hi,

first of thanks for this very awesome tool, it's very handy!

Migration from Point 1 to 6 works smoothly, but at Point 7 (Sales Data Migration) it seems like it went through all the data but failed in the end somehow and I can't proceed from there.

Error Message: Customer Taxvat is too long (maximum is 32 characters)

Error 500 implode(): Invalid arguments passed.

I'm using PHP 7.0.3 + Apache + MySQL 5.7.10

Any advice how to fix it ?

developer-lindner commented 8 years ago

Nevermind, found the issue and fixed it by modifying a few old entries with customer_taxvat value >= 32.

the0ckid82 commented 8 years ago

can you elaborate on what you did a little more im having this same issue but not sure what you mean or how you did it

thanks

developer-lindner commented 8 years ago

You got 2 options here.

First one, the bad approach, would be to modify your data. (Really bad idea) Second one, the better way, would be that you have a look here:

pub/ub-tool/protected/models/db/mage2

If you search for "customer_taxvat" you may notice that there are 2 files which extend ActiveRecord (ORM). Those files got "rules" in it, and if you look closer you will notice that the "max"-value is set to 32.

Increase it to 64 and restart the step. Import should work as expected now.

The cause for this issue is related to those rules and the sales data from magento1. One of the sales*-tables in magento1 saves e-mail addresses in the "customer_taxvat" column. And through the nature of mail addresses, those can become really really long ( => 32 ).

That's it.

(You may also have to change the reset script for that step.)

Cheers!