error on migrating active quotes

Status: fail
Message: CDbCommand failed to execute the SQL statement: SQLSTATE[HY000]: General error: 1366 Incorrect string value: ‘\xC2’ for column ‘city’ at row 1. The SQL statement executed was: INSERT INTO `quote_address` (`quote_id`, `save_in_address_book`, `same_as_billing`, `collect_shipping_rates`, `weight`, `subtotal`, `base_subtotal`, `subtotal_with_discount`, `base_subtotal_with_discount`, `tax_amount`, `base_tax_amount`, `shipping_amount`, `base_shipping_amount`, `discount_amount`, `base_discount_amount`, `grand_total`, `base_grand_total`, `free_shipping`, `address_id`, `created_at`, `updated_at`, `address_type`, `email`, `firstname`, `lastname`, `street`, `city`, `region_id`, `postcode`, `country_id`, `telephone`, `shipping_tax_amount`, `base_shipping_tax_amount`, `applied_taxes`, `subtotal_incl_tax`, `shipping_incl_tax`, `base_shipping_incl_tax`) VALUES (:yp0, :yp1, :yp2, :yp3, :yp4, :yp5, :yp6, :yp7, :yp8, :yp9, :yp10, :yp11, :yp12, :yp13, :yp14, :yp15, :yp16, :yp17, :yp18, :yp19, :yp20, :yp21, :yp22, :yp23, :yp24, :yp25, :yp26, :yp27, :yp28, :yp29, :yp30, :yp31, :yp32, :yp33, :yp34, :yp35, :yp36)

Question1 : How can we fix this and rerun from the last point when we are running command line for migration ?

Question 2: Also what if we dont want to continue quote migration or do it later while using magento2 ?

1 answer

Profile photo of Mall Staff 184060.00 $tone August 29, 2019
Public

Hi there,

1366 Incorrect string value: ‘\xC2’ for column ‘city’ at row 1. The SQL statement executed was: INSERT INTO `quote_address` 

That issue because your M1 database has bad data in value of ‘city’ field in table sales_flat_quote_address. To fix that, you could try with steps below:
+ Run below SQL in your M1 database:

Update sales_flat_quote_address set city = convert(binary convert(city using latin1) using utf8);

+ Once done, you could continue data migration in step #7 by run CLI command:
php -f bin/ubdatamigration run --step=7;

Question 2: Also what if we dont want to continue quote migration or do it later while using magento2 ?

The related quotes data of the sales orders data are required to migrate when you are migrating for sales orders.
Regards,
Mall.

#1

Please login or Register to Submit Answer

Written By

Comments