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
raj_sfdccraj_sfdcc 

Workbench is not throwing the error while updating account through before trigger?

i have below Trigger:
trigger AccountTrigger on Account (before update) {
    List<account> acclist=new List<account>();
    for(account acc:trigger.new){
        acclist.add(acc);
    }
    AccountTriggerHandler.updateaccount(acclist);
}

Class:
public class AccountTriggerHandler {
 Public static void updateaccount(List<account> acclist){
        List<account> updatelist=new List<account>();
        for(Account acc:acclist){
            acc.phone='90000324902';
                updatelist.add(acc);
        }}

So when iam triying updating records through Workbench  with account Name field as null also it is running fine.Ideally Account​ Name is RequiredField so we shoud get error while updating.iam confused weather it is due to order of execution or any other reason kindly help me out with this.
Ravi Dutt SharmaRavi Dutt Sharma
The account records is the list which you are iterating already have the account name populated on them. In addition to the name, you are populating the phone number. Why you are expecting it to throw an error?
raj_sfdccraj_sfdcc
In the CSV file iam giving the Name field as null and trying to update.that is why iam thinking of getting error.am i analysing wrong?