comment out or remove line 20 to 31 in map.xml file,
<!-- <ignore>
<document>sales_flat_creditmemo_grid</document>
</ignore>
<ignore>
<document>sales_flat_invoice_grid</document>
</ignore>
<ignore>
<document>sales_flat_order_grid</document>
</ignore>
<ignore>
<document>sales_flat_shipment_grid</document>
</ignore> -->
Add inside <document_rules>
tag of source tag,
<rename>
<document>sales_flat_order_grid</document>
<to>sales_order_grid</to>
</rename>
<rename>
<document>sales_flat_invoice_grid</document>
<to>sales_invoice_grid</to>
</rename>
<rename>
<document>sales_flat_creditmemo_grid</document>
<to>sales_creditmemo_grid</to>
</rename>
<rename>
<document>sales_flat_shipment_grid</document>
<to>sales_shipment_grid</to>
</rename>
Add below content under <field_rules>
tag of source tag.
<move>
<field>sales_flat_creditmemo_grid.grand_total</field>
<to>sales_creditmemo_grid.order_base_grand_total</to>
</move>
<!-- source table custom grid field-->
<ignore>
<field>sales_flat_invoice_grid.base_grand_total</field>
</ignore>
<ignore>
<field>sales_flat_creditmemo_grid.store_to_order_rate</field>
</ignore>
<ignore>
<field>sales_flat_creditmemo_grid.base_to_order_rate</field>
</ignore>
<ignore>
<field>sales_flat_creditmemo_grid.store_to_base_rate</field>
</ignore>
<ignore>
<field>sales_flat_creditmemo_grid.base_to_global_rate</field>
</ignore>
<ignore>
<field>sales_flat_creditmemo_grid.creditmemo_status</field>
</ignore>
<ignore>
<field>sales_flat_creditmemo_grid.invoice_id</field>
</ignore>
<ignore>
<field>sales_flat_creditmemo_grid.store_currency_code</field>
</ignore>
<ignore>
<field>sales_flat_creditmemo_grid.order_currency_code</field>
</ignore>
<ignore>
<field>sales_flat_creditmemo_grid.base_currency_code</field>
</ignore>
<ignore>
<field>sales_flat_creditmemo_grid.global_currency_code</field>
</ignore>
comment out or remove line inside <destination>
<document_rules>
tag,
<!-- <ignore>
<document>sales_creditmemo_grid</document>
</ignore>
<ignore>
<document>sales_invoice_grid</document>
</ignore>
<ignore>
<document>sales_order_grid</document>
</ignore>
<ignore>
<document>sales_shipment_grid</document>
</ignore>-->
Add below line inside <destination>
part of <field_rules>
tag
<ignore>
<field>sales_order_grid.billing_address</field>
</ignore>
<ignore>
<field>sales_order_grid.shipping_address</field>
</ignore>
<ignore>
<field>sales_order_grid.shipping_information</field>
</ignore>
<ignore>
<field>sales_order_grid.customer_email</field>
</ignore>
<ignore>
<field>sales_order_grid.customer_group</field>
</ignore>
<ignore>
<field>sales_order_grid.subtotal</field>
</ignore>
<ignore>
<field>sales_order_grid.shipping_and_handling</field>
</ignore>
<ignore>
<field>sales_order_grid.customer_name</field>
</ignore>
<ignore>
<field>sales_order_grid.payment_method</field>
</ignore>
<ignore>
<field>sales_order_grid.total_refunded</field>
</ignore>
<ignore>
<field>sales_invoice_grid.store_name</field>
</ignore>
<ignore>
<field>sales_invoice_grid.customer_name</field>
</ignore>
<ignore>
<field>sales_invoice_grid.customer_email</field>
</ignore>
<ignore>
<field>sales_invoice_grid.customer_group_id</field>
</ignore>
<ignore>
<field>sales_invoice_grid.payment_method</field>
</ignore>
<ignore>
<field>sales_invoice_grid.billing_address</field>
</ignore>
<ignore>
<field>sales_invoice_grid.shipping_address</field>
</ignore>
<ignore>
<field>sales_invoice_grid.shipping_information</field>
</ignore>
<ignore>
<field>sales_invoice_grid.subtotal</field>
</ignore>
<ignore>
<field>sales_invoice_grid.shipping_and_handling</field>
</ignore>
<ignore>
<field>sales_shipment_grid.customer_name</field>
</ignore>
<ignore>
<field>sales_shipment_grid.order_status</field>
</ignore>
<ignore>
<field>sales_shipment_grid.billing_address</field>
</ignore>
<ignore>
<field>sales_shipment_grid.shipping_address</field>
</ignore>
<ignore>
<field>sales_shipment_grid.billing_name</field>
</ignore>
<ignore>
<field>sales_shipment_grid.shipping_name</field>
</ignore>
<ignore>
<field>sales_shipment_grid.customer_email</field>
</ignore>
<ignore>
<field>sales_shipment_grid.customer_group_id</field>
</ignore>
<ignore>
<field>sales_shipment_grid.payment_method</field>
</ignore>
<ignore>
<field>sales_shipment_grid.shipping_information</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.billing_address</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.shipping_address</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.customer_group_id</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.order_status</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.customer_name</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.customer_email</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.payment_method</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.shipping_information</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.subtotal</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.shipping_and_handling</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.adjustment_positive</field>
</ignore>
<ignore>
<field>sales_creditmemo_grid.adjustment_negative</field>
</ignore>
save map.xml file and
run php magento migrate:data /var/www/html/{{magentoroot}}/vendor/magento/data-migration-tool/etc/ce-to-ce/{{CE version}}/config.xml
For Data migration from Magento 1 to Magento 2.
Your first step is Setting migrate,
command is:
php bin/magento migrate:settings /var/www/html/{{magento2}}/vendor/magento/data-migration-tool/etc/ce-to-ce/{{magento1 version}}/config.xml
All System -> Configuration
settings are migrated in setting migrate.
After completion of setting migrate, You need to check in Magento 2 Stores -> Configuration
setting.
In migrate setting, From your database table, core_config_data
have affected.
All Magento 1 settings are migrated to magento 2.
Thanks.
Best Answer
Yes, you can use the
data-migration-tool
for this, and I'd recommend to do so over any other methods: it will do the necessary field value conversions where needed.We were in a similar position as you: we imported product data (catalog, products) at an earlier point in time, then built the shop's design and functionalities and now will do a final data migration run for the customers, quotes, orders, logs and similar stuff.
In the
config.xml
, comment out the substeps you do not want to run again. in my case, I have the following disabled:data: eav step, url rewrite step, configurable prices step, tier price step, post processing step
in
map.xml
, I made sure to ignore all tables that I do not want the data to be migrated for.Be sure to include the necessary
<ignore><document>{tablename}</document></ignore>
in both sections (
<source>
and<destination>
(maybe called<target>
in older versions)).Be sure to test the migration on a copy of your db's (both magento 1.x and magento 2.x) as it can be quite destructive. It took me a few days and tries to get the mappings adjusted to our needs, but now the migration runs through without a hick.
I was not able to get the delta migration properly running with the above modifications, but in most cases, you'll only want to migrate the data just once before switching the new shop live.
If your 1.x shop has a fair amount of data, the migration process will take quite a while tho. be sure to run the migration in a
screen
shell session or similar to avoid data loss due to disconnects.