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

Multiple Ojects with the Data Loader

I have a spreadsheet that I want to be able to use with the data loader to upsert multiple objects in Salesforce, which, as far as I can tell, is possible using Apex and triggers. I am wondering though that if I am creating three objects based on a row in a spreadsheet, if I can back out the first two objects created if the thrid one fails for some reason, since I would either want all three of them or none of them to exist.


Also, would Apex triggers be the best approach for using one spreadsheet to upsert multiple objects, or would it be better to create three separate spreadsheets and then use batch scripting to run the data loader with all three?


My suggestion would be that best approach to implement your requirement would be through a third party tool built on PHP and as far your rollback functionality is concerned that too can be implemented by use of appropriate business logic in the third party program itself.


Did this answer your question? If not, let me know what didn't work, or if so, please mark it solved.




Thanks for the suggestion, but I think we are going to handle it with before insert triggers and custom settings.