- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-29-2023 12:32 AM
Hello,
Can anyone please let me know the exact answer i searched in community and googled it but i didn't find it.
1.Will current can be used in after business rule?If no, what is the alternative.
2.Using query BR and ACL we can restrict data which way you would prefer?why?
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-29-2023 02:23 AM
1. Will current can be used in after business rule?If no, what is the alternative.
Answer: current can be used in both before and after business rules. If you are referring to current.update() then it is not needed in before business rule. In case if you want to you in after business rule then try and see if your logic can be put in before business rule else if it has to be put in after business rule then make sure to put current.setWorkflow(false); and then do a current.update();
2.Using query BR and ACL we can restrict data which way you would prefer?why?
Answer: BR and ACL both can restrict data, however it is always recommended to use an ACL as the instance has the capability to cache the ACLs, hence the ACLs are more performant than query business rule. Also, it is easier to debug the ACLs using the ACL debugger than a query business rule.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-29-2023 12:46 AM
Hello Shaik22,
1) 'current' can be used in scripting when you are using BR; current's behaviors depends on when the BR is triggered, but if the BR it's after that means that the BR is going to be triggered after any action performed in the record, so your current value will be retrieved after the modification in this case if you change that value you are going to be able to retrieve the value before the modification.
2) From my point of view if there's a clear matrix with roles and restrictions I will avoid using coding for this and i will use ACL. However, if you need a more complex detailed visibility restrictions that can't be achieved using ACL I'll use BR query. In all the cases I will avoid using coding inside ACL script (if the requirement is complex).
☆ Community Rising Star 22, 23 & 24 ☆
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-29-2023 01:20 AM
1. when you use current. Update you need to include below steps in logic
current.setWorkflow(false);
current.update();
current.setWorkflow(true);
2. That depends on the requirement , ACL shows the stamps stating number of rows restricted but where as query BR does not show that
here is the support article for more understanding between ACL &Q BR
https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0859355
If this solution worked for you, please mark this as helpful & accept the solution as correct!
Regards,
Shyamkumar
Regards,
Shyamkumar

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-29-2023 01:41 AM
1. "Current" can be used in after business rule. Avoid using current.update() while writing a BR as much as you can.
2. It depends on your requirement. However, from user experience perspective, query BR should be preferred as it will not show "'Number of rows removed from this list by Security constraints" which is not preferred by many organizations.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-29-2023 02:04 AM
answer to above 2 questions is yes
Now it depends on what context the question was being asked.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader