Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot migrate order and invoice again using delta function #607

Closed
snowleo208 opened this issue Nov 7, 2018 · 3 comments
Closed

Cannot migrate order and invoice again using delta function #607

snowleo208 opened this issue Nov 7, 2018 · 3 comments

Comments

@snowleo208
Copy link

snowleo208 commented Nov 7, 2018

Hi, I tried to migrate my store from 1.9.3.4 to 2.2.6 but I encountered some problems. As I just use my copy of store database to do migration, now I missed some orders.

Situation

I tried to use a fresh database to migrate again, with the live database, but don't know why orders do not migrated. So I decided to use the database with missing orders to do migration of orders and customers using the method from #316, adding entries to m2_cl_* tables to live server.

Now I encountered an issue is: I successfully migrated new customers, but order, invoice and shipment do not update. I got the following:

100% [============================] Remaining Time: < 1 sec
[2018-11-07 00:12:36][WARNING]: Mismatch of entities in the document: sales_order_grid Source: 447 Destination: 439
[2018-11-07 00:12:36][WARNING]: Mismatch of entities in the document: sales_invoice_grid Source: 427 Destination: 419
[2018-11-07 00:12:36][WARNING]: Mismatch of entities in the document: sales_shipment_grid Source: 363 Destination: 359
[2018-11-07 00:12:36][WARNING]: Volume Check failed

[2018-11-07 00:12:36][WARNING]: Mismatch in last increment id of invoice entity
[2018-11-07 00:12:36][WARNING]: Mismatch in last increment id of shipment entity
[2018-11-07 00:12:36][WARNING]: Volume Check failed

I tried to update grid of m2_cl_eav_entity_store and I fixed the error of last increment id of order entity. However, not for shipment and invoices.

I guess may be I used module in magento 1, which will create the same number of shipment and invoice as order, e.g. 001 for invoice, shipment and order at the same time.

How can I fix this problem and migrate my missing orders, invoices and shipment? Thank you so much!

@victor-v-rad
Copy link
Collaborator

victor-v-rad commented Nov 7, 2018

Hi @snowleo208

\Migration\Step\SalesIncrement\Volume checks increment ids of invoice, shipment, order ... and not number of it between M1 and M2. So if you count
M1 sales_flat_invoice with M2 sales_invoice
M1 sales_flat_shipment with M2 sales_shipment
and they are equal, then most likely all invoices and shipments are in M2 DB.
internal ticket MAGETWO-96179 to make error message of SalesIncrement Step more clear

@snowleo208
Copy link
Author

How can I make the id match? As I start the delta progress, it shows me like this, and my order, invoice and shipment still have not updated:

[2018-11-07 23:46:46][INFO][mode: delta][stage: delta delivering][step: OrderGrids Step]: started
[2018-11-07 23:46:46][DEBUG][mode: delta][stage: delta delivering][step: OrderGrids Step]: sales_flat_order has changes
............
[2018-11-07 23:46:46][DEBUG][mode: delta][stage: delta delivering][step: OrderGrids Step]: sales_flat_order_address has changes....................
[2018-11-07 23:46:46][DEBUG][mode: delta][stage: delta delivering][step: OrderGrids Step]: sales_flat_invoice has changes.........
[2018-11-07 23:46:46][DEBUG][mode: delta][stage: delta delivering][step: OrderGrids Step]: sales_flat_shipment has changes.....
[2018-11-07 23:46:46][DEBUG][mode: delta][stage: delta delivering][step: OrderGrids Step]: sales_flat_order_payment has changes............
[2018-11-07 23:46:46][INFO][mode: delta][stage: volume check][step: OrderGrids Step]: started
100% [============================] Remaining Time: < 1 sec
[2018-11-07 23:46:46][WARNING]: Mismatch of entities in the document: sales_order_grid Source: 447 Destination: 439
[2018-11-07 23:46:46][WARNING]: Mismatch of entities in the document: sales_invoice_grid Source: 427 Destination: 419
[2018-11-07 23:46:46][WARNING]: Mismatch of entities in the document: sales_shipment_grid Source: 363 Destination: 359
[2018-11-07 23:46:46][WARNING]: Volume Check failed
[2018-11-07 23:46:46][INFO][mode: delta][stage: delta delivering][step: SalesIncrement Step]: started
[2018-11-07 23:46:46][INFO][mode: delta][stage: volume check][step: SalesIncrement Step]: started
100% [============================] Remaining Time: < 1 sec
[2018-11-07 23:46:46][WARNING]: Mismatch in last increment id of invoice entity
[2018-11-07 23:46:46][WARNING]: Mismatch in last increment id of shipment entity
[2018-11-07 23:46:46][WARNING]: Volume Check failed
[2018-11-07 23:46:46][INFO][mode: delta][stage: volume check][step: SalesIncrement Step]: Migration completed successfully
[2018-11-07 23:46:46][INFO][mode: delta][stage: volume check][step: SalesIncrement Step]: Automatic restart in 5 sec. Use CTRL-C to abort
[2018-11-07 23:46:51][INFO][mode: delta][stage: delta delivering][step: Customer Attributes Step]: started
[2018-11-07 23:46:51][INFO][mode: delta][stage: volume check][step: Customer Attributes Step]: started
100% [============================] Remaining Time: < 1 sec
[2018-11-07 23:46:51][INFO][mode: delta][stage: delta delivering][step: Log Step]: started
[2018-11-07 23:46:51][DEBUG][mode: delta][stage: delta delivering][step: Log Step]: log_visitor has changes
[2018-11-07 23:46:51][INFO][mode: delta][stage: volume check][step: Log Step]: started
100% [============================] Remaining Time: < 1 sec
[2018-11-07 23:46:51][WARNING]: Mismatch of entities in the document: customer_visitor Source: 5886 Destination: 12145
[2018-11-07 23:46:51][WARNING]: Volume Check failed
[2018-11-07 23:46:51][INFO][mode: delta][stage: delta delivering][step: OrderGrids Step]: started
[2018-11-07 23:46:51][DEBUG][mode: delta][stage: delta delivering][step: OrderGrids Step]: sales_flat_order_address has changes
....................
[2018-11-07 23:46:51][INFO][mode: delta][stage: volume check][step: OrderGrids Step]: started
100% [============================] Remaining Time: < 1 sec
[2018-11-07 23:46:51][WARNING]: Mismatch of entities in the document: sales_order_grid Source: 447 Destination: 439
[2018-11-07 23:46:51][WARNING]: Mismatch of entities in the document: sales_invoice_grid Source: 427 Destination: 419
[2018-11-07 23:46:51][WARNING]: Mismatch of entities in the document: sales_shipment_grid Source: 363 Destination: 359
[2018-11-07 23:46:51][WARNING]: Volume Check failed
[2018-11-07 23:46:51][INFO][mode: delta][stage: delta delivering][step: SalesIncrement Step]: started
[2018-11-07 23:46:51][INFO][mode: delta][stage: volume check][step: SalesIncrement Step]: started
100% [============================] Remaining Time: < 1 sec
[2018-11-07 23:46:51][WARNING]: Mismatch in last increment id of invoice entity
[2018-11-07 23:46:51][WARNING]: Mismatch in last increment id of shipment entity
[2018-11-07 23:46:51][WARNING]: Volume Check failed
[2018-11-07 23:46:51][INFO][mode: delta][stage: volume check][step: SalesIncrement Step]: Migration completed successfully

I have already put entity id that missed into m2_cl_* tables, e.g. 365 | INSERT | 0 in ks1_m2_cl_sales_flat_shipment.

This is my map.xml and I keep using the dist version of deltalog.xml, remain unchanged. I tried to use default map.xml of 1.9.3.6 but also did not migrate my missing orders etc.

Please give me some help. Thanks.

@snowleo208
Copy link
Author

I have successfully migrated all invoices and shipment after updated to the latest version, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants