Announcing the Saviynt Knowledge Exchange unifying the Saviynt forums, documentation, training,
and more in a single search tool across platforms. Read the announcement here.

Execute Extension Queries (CUSTOMQUERYJOB)got replaced with Enhanced Query Execution job

MichaelSchmid
New Contributor II
New Contributor II

Hell,

as we've upgraded to EIC, some of our crucial "Execute Extension Queries" needs to be updated/overwritten to be reused as an "Enhanced Query Execution job" .

Can some please help us here and tell us how this can be managed?

Please see for example the query below.
This query contains several Update parameters and is used to update newly added users and to assign them to an "Organization" and other things to make the users fully available in Saviynt.

 

UPDATE users u
SET u.customproperty35 =
(SELECT GROUP_CONCAT(DISTINCT user_groups.user_groupname ORDER BY user_groups.user_groupname ASC SEPARATOR ' ') AS 'Local Mitigating Controls Groups'
FROM usergroup_users, user_groups
WHERE user_groups.usergroupkey = usergroup_users.user_groupkey
AND usergroup_users.userkey = u.userkey )
WHERE u.userkey IN (SELECT userkey FROM usergroup_users, user_groups WHERE usergroup_users.user_groupkey = user_groups.usergroupkey AND (user_groupname LIKE 'WB-NL %'));

UPDATE users u
SET customproperty36 =
(select * from (select GROUP_CONCAT(uu.username ORDER BY uu.username ASC SEPARATOR ',') AS 'KeyUsersUsernamelList'
from usergroup_users ugu, user_groups ug, users uu
WHERE uu.userkey = ugu.userkey
and ugu.user_groupkey = ug.usergroupkey
AND ug.user_groupname = 'WB-NL') as subResult)
where u.customproperty10 = 1101;

UPDATE users u
SET customproperty37 =
(select * from (select GROUP_CONCAT(uu.email ORDER BY uu.email ASC SEPARATOR ',') AS 'KeyUsersEmailList'
from usergroup_users ugu, user_groups ug, users uu
WHERE uu.userkey = ugu.userkey
and ugu.user_groupkey = ug.usergroupkey
AND ug.user_groupname = 'WB-NL') as result)
where u.customproperty10 = 1101;

UPDATE users u
SET customproperty38 =
(select * from (select GROUP_CONCAT(uu.username ORDER BY uu.username ASC SEPARATOR ',') AS 'CFOUsernameList'
from usergroup_users ugu, user_groups ug, users uu
WHERE uu.userkey = ugu.userkey
and ugu.user_groupkey = ug.usergroupkey
AND ug.user_groupname = 'WB-NL_financedirector') as subResult)
where u.customproperty10 = 1101;

UPDATE users u
SET customproperty39 =
(select * from (select GROUP_CONCAT(uu.email ORDER BY uu.email ASC SEPARATOR ',') AS 'CFOEmailList'
from usergroup_users ugu, user_groups ug, users uu
WHERE uu.userkey = ugu.userkey
and ugu.user_groupkey = ug.usergroupkey
AND ug.user_groupname = 'WB-NL_financedirector') as subResult)
where u.customproperty10 = 1101;

UPDATE users SET customproperty33 = SYSDATE() +0 where customproperty10 = 1101;

UPDATE accounts a, users u, user_accounts ua
SET a.customproperty11 = 'WB-NL'
WHERE u.userkey = ua.userkey
and ua.accountkey = a.accountkey
and a.endpointkey !=2
and u.customproperty10 = 1101;

UPDATE accounts a, users u, user_accounts ua
SET a.customproperty10 = 1101
WHERE u.userkey = ua.userkey
and ua.accountkey = a.accountkey
and a.endpointkey !=2
and u.customproperty10 = 1101;

UPDATE users SET customer = 66
WHERE customproperty16 IN ('FUL','FAC','KIO','EXT')
AND customproperty10 = 1101;

UPDATE users u, customer c SET u.customproperty20 = c.customername
WHERE c.customerkey = u.customer
AND u.customproperty10 = 1101;

UPDATE users u
SET customproperty45 =
(select * from (select GROUP_CONCAT(uu.email ORDER BY uu.email ASC SEPARATOR ', ') AS 'KeyUsersEmailList'
from usergroup_users ugu, user_groups ug, users uu
WHERE uu.userkey = ugu.userkey
and ugu.user_groupkey = ug.usergroupkey
AND ug.user_groupname = 'WB-NL') as result)
where u.customproperty10 = 1101;


Thank you for your help.
BR, Michael Schmid

3 REPLIES 3

CR
Regular Contributor III
Regular Contributor III

Hi @MichaelSchmid 

Users table is not supported in Enhanced query.

try in API calls

Ref: https://documenter.getpostman.com/view/23973797/2s9XxwutWR#739655e0-a008-48b8-9cdd-faa67e7734be

or S4s Connection trough.

ref:

Based on user update rule you can trigger with action type import/UI

UPDATE users u
SET customproperty45 =
(select * from (select GROUP_CONCAT(uu.email ORDER BY uu.email ASC SEPARATOR ', ') AS 'KeyUsersEmailList'
from usergroup_users ugu, user_groups ug, users uu
WHERE uu.userkey = ugu.userkey
and ugu.user_groupkey = ug.usergroupkey
AND ug.user_groupname = 'WB-NL') as result)
where u.customproperty10 = 1101 and and u1.USERKEY='${user.id}'",

 

 


Thanks,
Raghu
If this reply answered your question, Please Accept As Solution and hit Kudos.

sai_kanumuri
Honored Contributor
Honored Contributor

Hi @MichaelSchmid 

Any existing queries configured prior to upgrade will still be supported by CUSTOMQUERYJOB job. Only the new queries going forward has to configured using Enhanced Query Execution job.

 

Regards,
Sai Kanumuri
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.

rushikeshvartak
All-Star
All-Star
  • You don't need to convert existing query (update) to enhanced Query (select)  
  • Existing queries will work as it is.
  • Any enhancement to existing custom query job can't be done and need to be create new enhanced query job

Custom Query block for existing job will become readonly / gray out.


 

rushikeshvartak_1-1707923097986.png

 

 

  • Enhanced Query Execution 

    • Introduced the Enhanced Query Execution job to improve the overall system stability in the Saviynt environment. See Enhanced Query Execution Job. in v23.7 Version

  • Enhanced Query Execution Job

    Introduced a new Enhanced Query Execution job to address potential security issues and improve the overall stability of the system in the Saviynt environment. The following changes have been implemented as part of this enhancement:

    • Discontinued the Execute Extension Queries (CUSTOMQUERYJOB): The existing job instances of Execute Extension Queries (CUSTOMQUERYJOB) continue to run. However, no new instances of this job can be created, and any attempt to modify the existing instances of the job are prevented by the system.

  •  
    • Supported Operations: The new Enhanced Query Execution job contains guardrails to limit updates on selected objects and support the INSERT and UPDATE operations.

      For more information, see Job Categories for Flat Job Control Panel in the Enterprise Identity Cloud Administration Guide.

https://docs.saviyntcloud.com/bundle/EIC-Admin-v23x/page/Content/Chapter10-Job-Control-Panel/Job-Cat...

Refer

https://forums.saviynt.com/t5/identity-governance/enhanced-query-saviynt-upgrade-to-v23-11/m-p/64669...


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.