Hello, getting the following error when importing sales:
Mage2SalesShipmentGrid: Customer Name cannot be blank.
is there a way to bypass this?
7 answers
Hi hisglassworks,
Shipping_name vs customer_name are required fields in Magento 2 but your database missing values of these fields.
Let’s open the php file at the path `/home/qvv/www/mg2/ce212-dev/pub/ub-tool/protected/controllers/Step7Controller.php`
and find to the code line:
$model2->customer_name = $model->shipping_name;
and replace it by code lines:
$model2->customer_name = $model->shipping_name;
if (empty($model2->customer_name)) {
$model2->customer_name = 'N/A';
}
And contact me if you need further assistance!
Regards,
Mall.
Tried that but same error. I ended up setting ALL customer names to N/A and that worked, so it must not be truly empty. Is there any downside to setting them all to N/A?
Hi hisglassworks,
The workaround I mentioned in previous reply referred to two required fields in Magento 2. Yet your M1 database lacked these two fields. Setting both to N/A as a tweak to pass the rules of M2.
This approach has no effect to your site, except for one thing that some entities in M2 still lacked such two fields (as per your M1 database)
Regards,
Mall.
Hi
I too got the same error and also tried above solution but still unable to solve the problem. Can you help me to fix this issue
Hi thisisadam,
I too got the same error and also tried above solution but still unable to solve the problem. Can you help me to fix this issue
Let’s provide me the admin and SSH credentials of your Magento2 now. I will check further and help you out.
Regards,
Mall.
Hi Mall,
I have sent login details through private message. Please check it.
Hi thisisadam,
Yeah, please follow my answers for your questions at here: https://www.ubertheme.com/question/customer-grid-reindex-status-processing/
Regards,
Mall.