mirror of
https://github.com/nocodb/nocodb.git
synced 2026-02-01 22:18:07 +00:00
really fix the batching logic
This commit is contained in:
@@ -269,13 +269,8 @@ async function createDemoTable({
|
||||
}
|
||||
|
||||
const BATCH_SIZE = 100;
|
||||
for (let i = 0; i < rowAttributes.length; i++) {
|
||||
await api.dbTableRow.bulkCreate(
|
||||
'noco',
|
||||
context.base.id,
|
||||
table.id,
|
||||
rowAttributes.slice(i * BATCH_SIZE, i * BATCH_SIZE + BATCH_SIZE)
|
||||
);
|
||||
for (let i = 0; i < rowAttributes.length; i += BATCH_SIZE) {
|
||||
await api.dbTableRow.bulkCreate('noco', context.base.id, table.id, rowAttributes.slice(i, i + BATCH_SIZE));
|
||||
}
|
||||
return table;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user