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
sureshsomepallisureshsomepalli 

Getting error while doing deployment

While validating the custom objects before deploying I am getting the following error,

 

Failure Message: "System.DmlException: Insert failed. First exception on row 0; first error: FIELD_CUSTOM_VALIDATION_EXCEPTION, Please choose a JRM or JCREC accordingly: []", Failure Stack Trace: "Class.TestTriggers.testCheckLoan: line 327, column 1"

 

Please help me on this.

 

Many Thanks in advance.

Best Answer chosen by Admin (Salesforce Developers) 
Raj10202Raj10202

Hi Suresh,

 

The error is due to a validation rule/loppkup filter while inser/updating a record at line 327 in class TestTriggers. Check for the validation rules or lookup filters(for the message Please choose a JRM or JCREC accordingly)  of the object you are inserting at line number 327. 

 

Insert the record which satisfies the ablove condition. Thanks.

 

Regards,

Raj