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

Department Change Notification

simrank
New Contributor II
New Contributor II

If any user's department gets changed from the Workday Import, how we can get a notification in our mailbox with both old and new value of the department attribute? 

Can anyone please assist here. 

16 REPLIES 16

rushikeshvartak
All-Star
All-Star

Use user update rule with Send Email Action


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

simrank
New Contributor II
New Contributor II

Thanks,

But, how can I add old value and new value of the department field in the norification?

To get what variables are present to use in the email template, check using the below expression. By putting it in the email body, it will print all variable names with values, and then accordingly, you can use it:


${this.binding.variables.each {k,v -> println "$k = $v" + "" + "br" + ">"}}

 

share result will guide further


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

simrank
New Contributor II
New Contributor II

I tested with this but looks like department value is not present as part of this. 

It gives user, requestor and manager details. 

Can you share results of code in text format 


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

simrank
New Contributor II
New Contributor II

Thanks but I was able to get the user department value using ${user?.departmentname}. 

It gives me the new value but not sure how to get the old value. 

With your shared string I get: 

entitlement_endpoint_list = []br> manager = 000ABCbr> createdBy = adminbr> service_accounts_list = []br> ownerOnTerminate = 000143br> serviceaccount_endpoints_list = []br> baseUrlForEmail = https://release-n-plus-one.saviyntcloud.com/ECMbr> user = 000GFYbr> requestor = YUVETHbr> entitlement_value_list = []br> out = java.io.PrintWriter@7dfd5089br> [entitlement_endpoint_list:[], manager:000ABC, createdBy:admin, service_accounts_list:[], ownerOnTerminate:000GFY, serviceaccount_endpoints_list:[], baseUrlForEmail:https://release-n-plus-one.saviyntcloud.com/ECM, user:000ABC, requestor:YUVETH, entitlement_value_list:[], out:java.io.PrintWriter@7dfd5089]

simrank
New Contributor II
New Contributor II

Also, how can I get entitlement details here in the notification of a specific endpoint ? Is that possible?

For both requirements variables are not exposed please submit idea ticket


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

Manu269
All-Star
All-Star

@simrank  as a workaround try with analytics to fetech the changes :

Doc link : Creating a report to fetch the User's History (saviyntcloud.com)

Regards
Manish Kumar
If the response answered your query, please Accept As Solution and Kudos
.

simrank
New Contributor II
New Contributor II

Thanks @Manu269 but we are in 2021 build as of now. 

 

Query should work in 23.x version also

Regards
Manish Kumar
If the response answered your query, please Accept As Solution and Kudos
.

simrank
New Contributor II
New Contributor II

Also, Can you check below query and let me know what's wrong here:
I have created an Update user rule which should be triggered when any user's dept gets updated and user is part of an entitlement which has "SCP" in it.

 

(##a.departmentname isupdated##) and a.statuskey=1 and a.id in (select distinct us.userkey from User_accounts us, Accounts ac, Account_entitlements1 ae1, Entitlement_values ev where us.accountkey = ac.id and ac.id = ae1.accountkey and ae1.entitlement_valuekey = ev.id and ev.entitlement_value like "%SCP-%" and ac.status = 1 and ac.endpointkey = 12)Screenshot 2024-02-08 at 5.13.14 PM.png

Account_Entitlements1 is not exposed 


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

Manu269
All-Star
All-Star

Account_Entitlements1 is not available in advanced query section

Regards
Manish Kumar
If the response answered your query, please Accept As Solution and Kudos
.

simrank
New Contributor II
New Contributor II

What should I use then to run this rule?

use below condition

(##a.departmentname isupdated##) and a.statuskey=1 and a.id in (select acc.id from Accounts acc,User_accounts ua,Account_entitlements1 ae,Entitlement_values ev where acc.id=ua.accountkey and acc.id=ae.accountkey and ev.id=ae.entitlement_valuekey and acc.status = 1 and ev.entitlement_value like '%SCP-%' and acc.status = 1 and acc.endpointkey = 12)


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