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
NewToSalesforce2012NewToSalesforce2012 

Tried to deploy got failure message for a class already in production that I didn't deploy

Hi,

 

I tried to deploy a class called "Birthday Name" from Sandbox to Production.

 

When I deployed it, I got an error Failure Message: "System.DML exception: Insert Failed. First Exception on row 0; first error: FIELD_CUSTOM_VALIDATION_EXCEPTION </BR> </BR> </BR> <font color="blue"> Redirecting in just a second. </font> </Br> <SCRIPT LANGUAGE="Javascript"> window.location = ../apex/SFSSDDupeCatcher_SFSSDupeCatcher? dld0=MDAxRjAWMDAwMG5TWHg4SUFH&scld=YT...

 

The odd part is I recieved this error message not on the class I was Deploying ("Birthday Name") but on a Test class for a class already in production. To my knowledge the class (and test class) is functioning correctly.

 

Why am I recieving this error? Is there anything I can do on my end to deploy my birthday name class to production?

HariDineshHariDinesh

Hi,

 

The reason might be a validation rule that exist in production org. check is there any validation rule that active in production org, which is not there in SBX.

If don’t want that validation rule deactivate it or change the test data accordingly.