You need to sign in to do that
Don't have an account?
Daniel Roberts
Apex Coding for Admins: Create a Trigger
I can't get the Workbench to create accounts.
All I am doing is copying code, so I'm not sure where it went wrong. I'm suspecting my object creation is not correct.
When I attempt to complete the challenge right before this one (title: Use DML to Persist sObjects to the Database) I get the following error:
The code I i'm using in Workbench to create the Recruiting Account:
Thanks,
All I am doing is copying code, so I'm not sure where it went wrong. I'm suspecting my object creation is not correct.
When I attempt to complete the challenge right before this one (title: Use DML to Persist sObjects to the Database) I get the following error:
EXCEPTION: System.DmlException: Insert failed. First exception on row 0; first error: FIELD_CUSTOM_VALIDATION_EXCEPTION, Account number must be 8 characters long.: [] STACKTRACE: AnonymousBlock: line 8, column 1 LINE: 8 COLUMN: 1
The code I i'm using in Workbench to create the Recruiting Account:
//Instantiate an object called acct from the sObject Account class Account acct = new Account(); //Set the attribute name of the acct object to Recruiting acct.name='Recruiting'; //Persist the acct object to the DB using DML Database.insert(acct);Any help?
Thanks,
@Abdul Khatri, I don't have any validation rules on my Account Number.