js + sequelize to insert 280K rows of data using JSON. The JSON is an array of 280K. Is there a way to do bulk insert in chunks. I am seeing that it takes a lot of time to update the data. When i tried to cut down the data to 40K rows it works quick. Am i taking the right approach. Please advice. I am using postgresql as backend.
PNs.bulkCreate(JSON_Small)
.catch(function(err) {
console.log('Error ' + err);
})
.finally(function(err) {
console.log('FINISHED + ' \n +++++++ \n');
});