OOB business rule Actual Start/End Date Validation firing with empty work end date

vktripper
Tera Contributor

We just upgraded our test instance to NY. I'm seeing an issue with the OOB business rule 'Actual Start/End Date Validation'.

find_real_file.png

I create a new change record and save it and see that this BR fires upon save with this message 'Actual Work End must be after Actual Work Start'. The log within the business rule shows that the actual end date gets a value of ''12-16-2019 02:23:25 PM" (not sure how this date is calculated and set on this field). 

find_real_file.png

  I have verified that the actual end date field is actually empty on the change record.

find_real_file.png

 

find_real_file.png

Any idea why this business rule might be firing?

18 REPLIES 18

Ashley Snyder1
Giga Guru

How are the Actual Start Date and Actual End Date fields being set on the form?  To assist in troubleshooting, you can right click on either of the fields and watch them when going through the new change creation/saving.  If you're creating a new change and setting the Actual Start Date manually, how is data being input into the Actual End Date field?  You mentioned a value above '12-16-2019 02:23:25 PM' which is technically before the Actual Start Date in your screenshot.  It sounds like the business rule itself seems to be working as intended,  but there's an issue with how data is being input into those fields.

Since your XML shows <work_end/> being empty, it seems like there's something client side that is occurring with the Actual End Date field (if you enter a value in that field and export the XML without saving the record, it's still empty) and once that action occurs the server side logic of the before business rule is conflicting with whatever is going on client side (as designed).  Watching the Actual End Date field upon form save should help to shed some light, as there may be an onSubmit client script or some other client side logic trying to set that field. 

Chaitanya Redd5
Tera Guru

Hi,

I see that the filter condition in the screenshot is different that the OOB one, might be the conditions were modified based on the requirement earlier. However, the filter condition clearly states that the Business Rule will be triggered when the Actual work start and Actual Work end is not empty and In the Screenshot of your change, I see that the Actual Work end is empty.

Could you please check for some other Scripts which sets the Actual work end field? There might be some script which is setting up the Actual work end as "12-16-2019 02:23:25 PM" and due to which the error message is thrown by Business Rule.

Kindly mark my answer as Correct and Helpful based on the Impact.

Regards,

Chaitanya

Noah Drew
ServiceNow Employee
ServiceNow Employee

Hello @vktripper !

I agree with Chaitanya. It appears the Filter Conditions were modified. I have attached a image of what the Out of the Box version looks like.

Try updating to this and see if the issue persists.

If it does, you can also check if there is a Default Value that is being populated for that Dictionary Entry.

And just an extra question: Is the Date being shown "12-16-2019 02:23:25 PM" always the same?

Hope that helps!

If it did, please mark as Helpful and consider setting the reply as the Answer to the question, thanks!

find_real_file.png

Are you sure your screenshot is OOTB?  I looked in a lab and PDI instance on New York and it doesn't match your screenshot, but it does match the OPs screenshot: