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
Elad Kaplan 3Elad Kaplan 3 

display exception message on data loader

I have a trigger that in few situations throws an exception which are cought .

I want to display the error message when the exception is cought on the data loader.

Any idea how to do it ?

Thanks!
bob_buzzardbob_buzzard
You can't display error messages in the data loader - if the operation fails then the error message will be shown in the error file that is produced once the dataloader has processed your file.  However, if you are catching the exception then the data load won't know that an error has occurred.  If you need to retain the error you'll have to store it in a custom object or the like to persist it outside of the load transaction, or send an email to a particular user.