Access rights and query restrictions can also be used to manage access authorizations and data access centrally and efficiently at data layer level.
In this article you will read the following content:
Configure access rights in the data layer
Note! Working with access rights at data layer level is particularly useful if you use a data layer on different pages and want to avoid having to set access rights for every component that uses the data layer.
1. Configure access rights in the data layer
- Open the corresponding data layer.
- Under the “Access Rights” menu item, you can add, edit or delete access rights for specific users and user groups.
2. Restricting the view of data
While you define which users or user groups are allowed to perform certain actions under Access Rights, you can use the “Query Restrictions” to ensure that only data records that the logged-in user is allowed to retrieve are loaded from the database table or view.
The example below shows this:
- Filter on the [project] column, which is assigned a server-side session variable.
This means that only the data records that match the filter criteria are loaded. In contrast to the filter via Data on the left in the components, the “Query Restriction” is executed on the server side and cannot be manipulated via the web client.
Note! The specified restrictions apply to all components that use this data layer.
- Always use “Data Restriction” for queries with a restricted view if the filter criteria and filter values are not to be changed by the user.
In combination with server-side session variables, queries can be restricted directly in the data layer against a table or view with freely definable filter criteria.