Does schedule jobs invoke inactive business rule

lakshmir
Giga Contributor

Hi All,

Does schedule jobs invoke inactive business rule.If so then how is it done.

Thank you

6 REPLIES 6

Chuck Tomasi
Tera Patron

Hi,



Inactive business rules are just that... inactive. They are not triggered by updates/inserts/deletes/etc made by scheduled jobs, transform maps, workflow scripts, or other business rules.



Please let me know if you have additional questions on this topic.


Akhil Parashara
ServiceNow Employee
ServiceNow Employee

I dont think so, I just reproduced it OOB, by calling an inactive BR thru sys_trigger and it did run

Yes, you "can" run a Business Rule that way and have it execute, BUT, that is not the way you should do things anymore.  

A good (or bad, really) example of that is the "Autoclose Incidents" Schedule Item - it runs the "incident autoclose" Business Rule.  That particular BR is setup on the Incident table, but will NOT trigger based on any database operation (none of the Insert, Update, Delete or Query checkboxes are selected).

This goes back to the days where Scheduled Script Executions and Script Includes did not exist yet, so this is how things had to be done.  Now, Business Rules should really only be triggered by database operations and you should leverage Scheduled Script Executions and Script Includes where appropriate.

Although there are still examples of the old way of doing things, do not add any more.

So, to summarize, you can programmatically "run" an inactive BR, that same inactive BR will NOT be "triggered" by a database operation.

Service_RNow
Mega Sage

Hi,

You can do the vice versa, invoke an onDemand scheduled job from a BR(or any serverside script) but not the opposite.

Refer: Can a schedule job invoke an inactive business rule?

Thanks