How to skip old orders and speed up the migration

Hi, I am now upgrading the sales data. I have large sum of old sales record because we used to sell lots of low value items, and order generated from eBay through m2epro. Order history shows there are around 350,000 records over past 8 years. According to current system speed which ssows around 100 records being migrated over 2 minutes period. It could take forever to finish teh migration. Just wondering if we can skip the old orders, and speed up the process?
Or if possible we can delete orders from M 1 store, do you have any suggestions?
Regards,
Josh

3 answers

Profile photo of Mall Staff 184060.00 $tone March 21, 2020
Public

Hi Josh,

Just wondering if we can skip the old orders, and speed up the process?
Or if possible we can delete orders from M 1 store, do you have any suggestions?

Please let me know what is the version of our module in your instance now?

If you run the delta migration in step #7 without the ‘update’ mode, our tool only migrates newly added sales data in M1. It doesn’t cover the migrated sales data (old sales data).
 
Regards,
Mall.

#1
Profile photo of Joshua Denne 200.00 $tone March 21, 2020
Public

Hi, Mall, thanks for your response. 
When I said old sales data, I mean historic sales records.
I am using pro version to upgrade from M 1.9.3 to M 2.3.4. I am using the CLI command mode to upgrade the complete sales data. It is going on slowly, but 30k has been done. Expected to finish it in 3 days unless you have any ideas to stop copying the older records pior to Jan 1, 2015?
Regards,
Josh

#2
Profile photo of Mall Staff 184060.00 $tone March 23, 2020
Public

Hi Josh,

Expected to finish it in 3 days unless you have any ideas to stop copying the older records pior to Jan 1, 2015?

What is the version of our module in your instance now?

If you are using the latest Pro version 3.2.3, to filter as you want you can follow steps below:

+ Open the PHP file at: pub/ub-tool/protected/controllers/Step7Controller.php
and find the code lines:

if ($this->runMode == UBMigrate::RUN_MODE_DELTA) {
$lastMigrationTime = UBMigrate::getLastMigrationTime($this->stepIndex, 'sales_flat_order');
if (!empty($condition)) {
$condition .= " AND updated_at >= '{$lastMigrationTime}'";
} else {
$condition = "updated_at >= '{$lastMigrationTime}'";
}
}

and replace it with:

if ($this->runMode == UBMigrate::RUN_MODE_DELTA) {
$lastMigrationTime = UBMigrate::getLastMigrationTime($this->stepIndex, 'sales_flat_order');
if (!empty($condition)) {
$condition .= " AND updated_at >= '{$lastMigrationTime}'";
} else {
$condition = "updated_at >= '{$lastMigrationTime}'";
}
}
if (!empty($condition)) {
$condition .= " AND created_at >= '2015-01-01 00:00:00'";
} else {
$condition = "created_at >= '2015-01-01 00:00:00'";
}

Regards,
Mall.
 

#3

Please login or Register to Submit Answer

Written By

Comments