0

I am using FlexiDB Server, when I insert 1000 rows using the command below it takes some time:

$.collection('collection_name').insert(row);

How can this be accelerated?

Ben Osborne
  • 218
  • 4
  • 15

1 Answers1

0

You can use the command insert_bulk, create an array to hold all of your objects and then use the command insert_bulk to insert all at once.

$.collection('collection_name').insert_bulk(rows);
Ben Osborne
  • 218
  • 4
  • 15