ANS-0024 · SAVED SEARCHES & FORMULAS

How to Reference the Current User’s Role in a NetSuite Saved Search?

Quickly identify the current user's role in NetSuite saved searches for dynamic results.

Short answer

To reference the current user's role in a NetSuite saved search, use the system variable `{userrole}`. This variable dynamically retrieves the role of the user executing the search, allowing for role-specific filtering or display of results. This method is confirmed to work effectively.

Scenario

Users often need to create NetSuite saved searches that display or filter results based on the role of the individual running the search. This requirement arises when different roles should see distinct data sets or have specific permissions reflected in their search outputs. Identifying the correct method to dynamically reference the current user's role within a saved search formula or criteria can be challenging.

Solution

To successfully reference the current user's role within a NetSuite saved search, the system variable {userrole} should be utilized. This variable dynamically retrieves the role of the user currently executing the saved search. Implement {userrole} directly within your saved search criteria or results formula to achieve role-specific data presentation or filtering. This functionality has been tested and confirmed to operate as expected.

Expert NetSuite Support

Need help with this NetSuite issue?

Saved Searches & Formulas consulting and configuration support

Talk to a consultant