Announcing the SAVIYNT KNOWLEDGE EXCHANGE unifying the Saviynt forums, documentation, training, and more in a single search tool across platforms. Click HERE to read the Announcement.

Multi-user request error when using

BrandonLucas_BF
Regular Contributor III
Regular Contributor III

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:

 

BrandonLucas_BF_0-1678979533696.png

I can see in the logs errors like the following are generated:

{"log":"org.codehaus.groovy.grails.web.pages.exceptions.GroovyPagesException: Error processing GroovyPageView: Error executing tag \u003cg:form\u003e: No such property: ID for class: groovy.sql.GroovyRowResult\n","stream":"stdout","time":"2023-03-14T20:49:32.498475764Z"}
 
{"log":"Caused by: org.codehaus.groovy.grails.web.taglib.exceptions.GrailsTagException: Error executing tag \u003cg:form\u003e: No such property: ID for class: groovy.sql.GroovyRowResult\n","stream":"stdout","time":"2023-03-14T20:49:32.498501693Z"}
 
Though not obvious, it was realized that this is related to the dynamic attributes. I deleted them and the issue went away. However, this isn't a solution as we need these dynamic attributes to work and multi-user is also important.
 
I believe this is because we are using SQL ENUM for 2 of the 3 dynamic attributes. The second attribute is based on the first selection (BOOLEAN). It appears that multi-user request has trouble with the SQL ENUM attribute type. When I re-add the BOOLEAN dynamic attribute only, it does show up on the multi-user request:
 
BrandonLucas_BF_1-1678979951090.png

 

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

 

1 REPLY 1

DaanishJawed
Saviynt Employee
Saviynt Employee

Hi @BrandonLucas_BF ,

  • It is not mandatory for SQLENUM attribute type to have a parent attribute.
  • In your second dynamic attribute which is as below, since you are referring to the first dynamic attribute which is ${CoupaCustomer} and its result set, you will have to mention ${CoupaCustomer} as the parent attribute in order for the second dynamic attribute to evaluate.

 

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'
  • Now for your third dynamic attribute query which is as below (shared by you above), can you try with the modified query shared below and with the Parent Attribute field as blank.

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.