Before You Begin
Make sure you have:- Admin access to your WisdomAI domain.
- A clear understanding of the table you want to secure.
- (Optional) User attributes or entitlement tables already set up for dynamic filtering.
Configure RLS on a Table
Find below the steps to configure row-level security for a table in your WisdomAI domain.1. Open the RLS Configuration
- In your WisdomAI domain, go to the Tables tab and locate the table you want to secure.
- Click the three-dot menu on the right side of the row and select Row-Level Security.
- The Row-Level Security Configuration modal screen opens.
2. Define the SQL Filter
- In Describe Filters, optionally enter a short description of your security requirement (for documentation purposes).
- In the SQL text box, enter the
WHERE
clause that defines which rows are visible. - You can use Wisdom’s built-in functions for dynamic, user-aware filtering. For a complete list of functions and examples, see Dynamic Filters with Custom Functions in our guide to understanding RLS.
- Optionally, you can check the Set as entitlements table option. This help you define which users can access which resources. To learn more about the core concepts behind entitlements tables, refer to the Understanding Row-Level Security guide.
3. Preview the Filter
- Click Preview.
- In the Preview Table with Row-Level Security modal, enter the email of a user in the User Email field.
- Click Impersonate to see how the table appears for that user.
- (Optional) Add temporary custom user attributes in the preview for advanced testing.
4. Save the Configuration
- When the filter behaves as expected, click Save to apply it.
- The filter will now be automatically added to all queries involving this table.
- To disable RLS on a table, clear the SQL text box and save again.
Optional Adjustments
For more advanced use cases, refer to the Understanding Row-Level Security guide to learn about:- Applying RLS to Admin Users: By default, admins bypass RLS. You can change this behavior in the domain’s Advanced tab.
- Using Entitlement Tables: For complex permission models, you can use an entitlements table to manage access.