We are currently experiencing intermittent login issues on Community.  The team is actively working on a fix.

How can I run my configure ACL First to hide some record based on a variable value?

Chandra18
Mega Sage

Hi Team,

 

I have a custom table x_custom_table that contains a field related_table (field type = Table).

This field references different tables such as x_gisr, x_ara, etc.

 

Requirement:

I want to hide all records from the list and form view where related_table = x_gisr,

for all users (including admin) if user not having x_security (Custom role) but another record should be able to see where related_table != (is not) x_gisr ,in other word... only user having x_security role can see the records where related_table = x_gisr. 

I have write some read ACL with taking that role in role section and data condition but not working.
I have  check "Show ACL Execution Plan" (feature : Related link on ACL) , it is showing some ACL run before current (My ACL) but I have deactivated all it is not working still.

How can I write the ACL please Guide.

Thank You in advance!!!





9 REPLIES 9

@Ankur Bawiskar 
Business want to achieve this by ACL, Record count are in 10 lakhs +, I suggested the same way and I have shown but they reject this solution due to performance issue.

@Chandra18 

since there are 10lakhs+ it's recommended to use query business rule to club the records.

If you don't use query business rule then user will have to scroll next pages to see the allowed records as records will be scattered across pages.

Convince customer as that's the recommended way forward.

6 Ways to Eliminate ‘Rows Removed by Security Constraints’ Message in ServiceNow 

Before Query Business Rule Vs ACL 

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Hi @Ankur Bawiskar 

Chandra18_0-1761560105147.png

Getting this best practice error at the time of saving

 

@Chandra18 

is that an outcome from health scan or instance scan? 

I think you can still proceed and this can be accepted considering you have 10lakhs + records.

Sometimes you need to exclude best practice for better UI experience for customers.

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

J Siva
Kilo Patron
Kilo Patron

@Chandra18 Please share the picture of your ACL and script..