Saviynt unveils its cutting-edge Intelligence Suite products to revolutionize Identity Security!
Click HERE to see how Saviynt Intelligence is transforming the industry.
Saviynt Copilot Icon

SQL Query to retrieve all the entitlements - DisplayName for a user

void0703
New Contributor III
New Contributor III

Hi All,

I want a SQL query that will give me the list of user along with the entitlements they have assigned to them.

Please let me know if we can do it.

Thanks,

2 REPLIES 2

pmahalle
All-Star
All-Star

Hi @void0703 ,

Use below query, which will give you list of all the entitlements assigned to user across all the endpoints

SELECT
U.USERNAME, E.ENTITLEMENT_VALUE
FROM
USERS U, USER_ACCOUNTS UA, ACCOUNTS A, ACCOUNT_ENTITLEMENTS1 AE, ENTITLEMENT_VALUES E
WHERE
U.USERKEY = UA.USERKEY AND
UA.ACCOUNTKEY = A.ACCOUNTKEY AND
A.ACCOUNTKEY = AE.ACCOUNTKEY AND
AE.ENTITLEMENT_VALUEKEY = E.ENTITLEMENT_VALUEKEY


Pandharinath Mahalle(Paddy)
If this reply helps your question, please consider selecting Accept As Solution and hit Kudos 🙂

DixshantValecha
Saviynt Employee
Saviynt Employee

Hi @void0703 ,

Please validate the below query:-

SELECT
U.USERNAME,
E.ENTITLEMENT_VALUE
FROM
USERS U
JOIN
USER_ACCOUNTS UA ON U.USERKEY = UA.USERKEY
JOIN
ACCOUNTS A ON UA.ACCOUNTKEY = A.ACCOUNTKEY
JOIN
ACCOUNT_ENTITLEMENTS1 AE ON A.ACCOUNTKEY = AE.ACCOUNTKEY
JOIN
ENTITLEMENT_VALUES E ON AE.ENTITLEMENT_VALUEKEY = E.ENTITLEMENT_VALUEKEY;