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

Workflow Custom Assignment for Secondary manager and manager

Harish7
New Contributor II
New Contributor II

Hi,

I am trying to assign user's manager and secondary manager as the Assignee of access request using workflow custom assignment.

I tried to use the below query but didn't work.

query: select userkey from users where manager = ${user.manager} and secondarymanager = ${user.secondarymanager}

Harish7_0-1658154002129.png

 

Could you please assist on this?

 

Thanks in advance.

 

Best regards

Harish

7 REPLIES 7

rushikeshvartak
All-Star
All-Star

select manager as userkey from users where userkey = ${user.id}  union select SECONDARYMANAGER as userkey from users where userkey = ${user.id} 


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

Harish7
New Contributor II
New Contributor II

Hi Rushikesh,

Thank you for the reply.

I tried accordingly with secondaryManagerId. But it is not assigning the correct Assignee.

Query: select userkey from users where manager = ${user.manager} and secondarymanager = ${user. secondaryManagerId}

Could you please check if there is any mistake in the query or is there any other alternative?

Thanks

Harish

if you want to assign approval to manager & secondary manager please use query from above post


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

Harish7
New Contributor II
New Contributor II

Hi Rushikesh,

Thank you.

I have tried to use that query in workflow and assign the workflow to a security system.

But is not assigning the correct assignees in the ARS. It is assiging the random user as assignee.

Queryselect manager as userkey from users where userskey = ${user.id}  union select SECONDARYMANAGER as userkey from users where userskey = ${user.id} 

Workflow:

Screenshot 2022-07-18 at 17.27.12.png

And also the request is not opening in ARS. It fails with the below error in the screenshot:

Screenshot 2022-07-18 at 17.34.20.png

Harish,

You have a typo in the workflow's custom query. It's userkey not userskey .

 

 

Regards,
Avinash Chhetri

please select user field as Custom Query not user Group

rushikeshvartak_0-1658160878908.png

 


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

Harish7
New Contributor II
New Contributor II

Thanks @rushikeshvartak and  @avinashchhetri it worked. I made your comment as Accepted Solution.

But i there is a small typo in it, as @avinashchhetri mentioned - It's userkey not userskey

If possible please edit this in the solution.