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
ElkayElkay 

FIELD CUSTOM VALIDATION EXCEPTION

Insert failed. First exception on row 0; first error: FIELD_CUSTOM_VALIDATION_EXCEPTION, You can not save an SR Line Item using the "(New)" product.: [EP_Product__c]
Error is in expression '{!save}' in component <apex:commandButton> in page samplerequestnew: Class.SampleRequestNewController.save: line 86, column 1
An unexpected error has occurred. Your development organization has been notified.
James LoghryJames Loghry
You're running into a custom validation rule that you or one of your admins or developers has created.  You'll need to create the record so that it satisfies your validation rule.
Felix CruzFelix Cruz
I am working on the Admin Intermediate module and have run into this issue with the Process Builder module.

There was an unexpected error in your org which is preventing this assessment check from completing: System.DmlException: Insert failed. First exception on row 0; first error: FIELD_CUSTOM_VALIDATION_EXCEPTION, Account number must be 8 characters long.: []

I thought it might be that the existing account records failed to meet validation criteria as they pre-existed creation of validation rules.  However I continue to receive this error even though every account record meets all of the validation criteria.  I tested this by opening every Account record and doing a save, correcting all errors until save was successful.  Any ideas?