function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Prince PranavPrince Pranav 

Can we insert multiple object records via static resources?

Can we insert multiple object records via static resources? 

Like for Account , Contact and a custom object, i want to insert TXT/CSV files ? Please post ur ideas on this?
Sai PraveenSai Praveen (Salesforce Developers) 
Hi Prince,

You mean you want to insertvthe static resource with multiple records and using that static resource so you insert the record?

Thanks,
 
Prince PranavPrince Pranav
Yes @Sai Praveen
Sai PraveenSai Praveen (Salesforce Developers) 
Hi Prince,

You cannot insert as such when you try to insert there may be diffirent fields on each object and also it fails with error saying that field is not present in that object.

You may need seperate static resources for each object.

If this solution helps, Please mark it as best answer.

Thanks,