1

I am running into an issue when running an update using the mass data loader. I run the same update twice per week, however, this week, a new validation rule that I created is throwing a validation error. The catch is that it is finding errors where none exist. I navigated to the error records and manually Edited and Saved, and no validation error is being thrown.

Additionally, it is weird b/c I updated 2848 records and the first 2600 threw 0 errors, and the 148 errors all came in the last 248 records updated.

Any idea what could be causing this?

FYI: I de-activated the validation rule and the update ran without errors, however, the validation rule is relatively simple and was only a slight modification to another existing (and functioning) rule, so I'm not sure what's causing the error.

The error-causing rule:

AND( 
  ISPICKVAL( Status__c , 'Ready for Submission'), 
  ISPICKVAL( Investment_Powers__c , '' ) 
)

Another rule that does not cause an error:

AND( 
  ISPICKVAL( Status__c , 'Ready for Submission'), 
  ISPICKVAL( Branch_Code__c ,'') 
)

Additionally, all of the records that caused errors had the status 'Open', so I'm not sure what's going on here.

Thanks in advance!

11
  • Are you loading in the values of Status__c as expected in the Validation rules, or are you relying on some Before Triggers to set those values before encountering the validation? Oct 18, 2012 at 16:11
  • Status__c is being updated by the mass update, in addition to one other field, 'Current_Value__c'. Oct 18, 2012 at 16:23
  • There is a before trigger in play, but it does not touch either of those fields at all. Oct 18, 2012 at 16:23
  • What value of investment_powers__c are you loading? What incumbent value do the erring records have? Oct 18, 2012 at 17:04
  • 1
    @LaceySnr The Investment_Powers__c field didn't even exist when the trigger was written and deployed, so there is no way that it is editing that field Oct 22, 2012 at 18:10

1 Answer 1

1

It sounds like the status__c is getting changed to 'Ready for Submission' in the load. If that is definitely not happening I would change the second part to

ISBLANK(TEXT(Investment_Powers__c))

I have had issues with ISPICKVAL( Investment_Powers__c , '' ) style before.

If these do not work, can you set the debug log and copy the section of when this runs?

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .