Bulk Record Creation

sb458
Tera Expert

I have a requirement where I have to create Engagements for all the Companies(core_company) which has an associated supplier in Supplier (sn_fin_supplier) table.
Note: There are close to 2 lacs records in Supplier table. I could not create any custom field on Company table.
How can I make sure Engagements get created for all the companies either in batch or one go considering performance?

1 ACCEPTED SOLUTION

sb458
Tera Expert

I have implemented a fixed script that runs in the background during off hours, and it effectively handles the task.

View solution in original post

6 REPLIES 6

Hanna_G
Tera Guru

Hi @sb458 

Could you do this using Flow Designer? 
Trigger - Run Once
Then do a look up Companies with supplier, and for each Create Record - record type Engagement? 
You would need to increase the number of times to execute to match the size required. 

Can you elaborate more on " Increase the number of times to execute to match the size required."?

Hi @sb458

 

In your Look up records step there is a Max results option: 

Hanna_G_0-1751970948061.png

Update here to ensure that you capture all of the records needed. 

JaredNash
Giga Contributor

Use scheduled script or Flow Designer with batch processing and pagination to handle large data safely.