To find out permissions on a certain table, in this case AERole, open the Designer, navigate to the tab "Permissions", select the table "AERole" and click "Edit Permissions" from the task area. In the "Summary of all permissions for AERole" you can find the permission groups with their assigned permissions on the table, you can also see if there are any conditions on them. To watch them in detail you may want to right click a group and select "Select in permissions editor", then you can switch to the "Group Permissions for table" tab and the "Permissions filter sub-tab, where you can see the details for any conditions.
As this may be a tedious process for a number of groups, it may be easier to create a query based on the following SQL statement to find out which groups have permissions:
SELECT dg.GroupName, dtgr.* FROM DialogTableGroupRight dtgr
LEFT JOIN DialogGroup dg ON dtgr.UID_DialogGroup = dg.UID_DialogGroup
This returns all permission groups that have any permissions on the table AERole. It may be useful to filter further based on the given permission (e.g. CanInsert and InsertWhereClause).
In the given case of the AERole, further specification of the WhereClauses are based on the UID_ParentOrg portion of the AERole. To find out how the basetrees in the Identity Manager, where you add the AERoles to, translate to UID_Orgs, you can use the following query:
SELECT btc.*,bt.Fullpath FROM BaseTreeCollection btc
LEFT JOIN dbo.Basetree bt ON bt.UID_Org = btc.UID_Org
WHERE btc.UID_Org like 'DEFAULT%'
The information in the script(s) provided is known to work successfully; however, they have not been officially tested by One Identity Quality Control. If any of these instructions are changed and/or incorrectly used, intentionally or unintentionally, this solution becomes unsupported by One Identity Support and Development. Support and Development recommend always making a backup of the current database prior to execution of any script(s) that may modify it. For customization of One Identity Manager, please contact our Professional Services Organization.