Optimize database import queries with improved index selection

This commit is contained in:
2025-01-29 18:42:29 -05:00
parent fb5bf4a144
commit 0d377466aa
3 changed files with 187 additions and 4 deletions

View File

@@ -52,7 +52,7 @@ async function importOrders(prodConnection, localConnection) {
let processed = 0;
// Process in batches
const batchSize = 20000; // Increased from 1000 since order records are small
const batchSize = 10000; // Increased from 1000 since order records are small
let offset = 0;
while (offset < total) {