Click HERE to see how Saviynt Intelligence is transforming the industry. |
03/16/2023 08:29 AM
In our development environment we're testing adding a few dynamic attributes to one of our endpoints to be used during requests. When doing this, we unfortunately have seen some negative impact for multi-user requests for the same endpoint. When doing a multi-user request, the entitlement list portion of the process throws this error:
I can see in the logs errors like the following are generated:
When I add the second dynamic attribute, SQL ENUM, it also shows up. The attribute has the first one as a parent attribute and the action is 'Mapping'. Here is the query:
SELECT DISTINCT CASE WHEN ${CoupaCustomer} = 'FALSE' THEN ev.entitlement_value WHEN ${CoupaCustomer} = 'TRUE' THEN concat('AR_', (select u.customproperty5 from users u where userkey in (826))) END AS ID FROM entitlement_values ev where ev.entitlementtypekey = '349'
When I add the third dynamic attribute, the issue returns. This attribute does not have a parent attribute or action. I thought maybe it was the SQL query:
SELECT CASE WHEN ((select USER_GROUPNAME from user_groups WHERE USERGROUPKEY in (select USER_GROUPKEY from usergroup_users where userkey in (${requestor}) AND USER_GROUPKEY = 64 ))) = 'CoupaAdmin' THEN 'ITRequestable' ELSE 'Requestable' END AS 'CoupaUserType'
However, I tested making the first attribute a parent attribute of this one, and set the action as 'Refresh' and that clears the error. Do SQLENUM attributes require a parent attribute? Seems odd to be a requirement.
Originally I opened a ticket on this but was redirected here after initial troubleshooting:
https://saviynt.freshdesk.com/support/tickets/1609400
Solved! Go to Solution.
03/22/2023 03:30 PM
Hi @BrandonLucas_BF ,
SELECT DISTINCT CASE WHEN ${CoupaCustomer} = 'FALSE' THEN ev.entitlement_value WHEN ${CoupaCustomer} = 'TRUE' THEN concat('AR_', (select u.customproperty5 from users u where userkey in (826))) END AS ID FROM entitlement_values ev where ev.entitlementtypekey = '349'
Your Query -
SELECT CASE WHEN ((select USER_GROUPNAME from user_groups WHERE USERGROUPKEY in (select USER_GROUPKEY from usergroup_users where userkey in (${requestor}) AND USER_GROUPKEY = 64 ))) = 'CoupaAdmin' THEN 'ITRequestable' ELSE 'Requestable' END AS 'CoupaUserType'
Modified Query -
SELECT CASE WHEN ((select USER_GROUPNAME from user_groups WHERE USERGROUPKEY in (select USER_GROUPKEY from usergroup_users where userkey in (${requestor}) AND USER_GROUPKEY = 64 ))) = 'CoupaAdmin' THEN 'ITRequestable' ELSE 'Requestable' END AS 'ID'
Thanks.