Domain seperation for custom table without adding the domain field
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-14-2023 02:10 AM
Hi All,
We have a requirement to domain separate a variable table with out adding the domain field
when ever user logged in to that table only that user domain records will be visible
Let me know your suggestions on this
Thanks in advance.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-14-2023 05:33 AM
Hi @Venkatesh48
If you have a requirement to domain-separate records in a variable table in ServiceNow without adding a domain field directly to the table, you can achieve this by leveraging security rules and ACLs (Access Control Lists) to control access to records based on the user's domain affiliation.
Security Rules:
- Create a security rule that limits the records accessible to users based on their domain affiliation. Security rules allow you to define conditions that determine which records users can access.
ACLs (Access Control Lists):
- Configure ACLs on the variable table to enforce the security rules you've defined. ACLs specify who can perform specific actions on records.
Contextual Security Filters:
- Use contextual security filters in ACLs to filter records based on the user's domain affiliation. You can use the gs.getUser().getDomainID() function to obtain the user's domain ID and use it as a filter condition in the ACL.
Mark the comment as a correct answer and also helpful if this has helped to solve the problem.
Krishna Sharma