Click HERE to see how Saviynt Intelligence is transforming the industry. |
08/14/2024 08:16 AM - edited 08/14/2024 08:16 AM
Hello,
I have a requirement where, when the HCM-Status is set to "I", the "Paused Started Date" (which we have mapped to customproperty6) should automatically be cleared and set to empty.
How can we ensure that when the HCM-Status is "I", the Paused Started Date attribute (customproperty6) is empty by default? I've tried implementing this using a user update rule, but since custom actions cannot be used, I'm unable to specify that CP6 should be cleared. is this needs to be handled specifically in a SAVtoSAV connection?
This issue also occurs in other scenarios when we change a mapping to a different custom property (CP). After the import, the old CP value is not cleared automatically, and we end up doing it manually. What could be causing this problem, and how can we resolve it?
Solved! Go to Solution.
08/14/2024 08:20 AM
08/16/2024 12:55 AM
Thank you, could you please explain the following, basically i created a user update rule but how do i set the action to clear the "customproperty6 " which is paused start date
08/16/2024 02:48 AM
Hi @Roua ,
Select update login as an option then attach a connection to the user update rule .
In the connection handle our use case to remove the cp6 value using rest API
08/16/2024 04:50 AM
Thank you @NM ,
i did as you recommended,
i have a connection for the HCM system and AD already and i have these two jobs for it
In updateuserjson in AD:
"customproperty6": "${if(user.customproperty5 == 'P' || user.customproperty5 == 'I'){''} else {user.customproperty6}}",
in MODIFYUSERDATAJSON in HCM:
"UPDATE NEWUSERDATA NU SET NU.customproperty6 = NULL WHERE NU.customproperty5 IN ('P', 'I')",
the jobs for HCM
after changing the status to I
this triggered the user update rule and created tasks
and after running the past jobs it still didn't work and the tasks are there.
i have a similar issue with the opposite that the accounts deactivated and the pause start date is set to current day, the tasks for AD / LDAP work after running the provisioning Jobs but for the users it doesn't and the date also won't be set.
can you please explain to me what is the wrong step / concept here? how to deal with it ?
08/16/2024 04:56 AM
Hi @Roua , if you want to update customproperty of saviynt to blank .. attach a saviynt rest connection will blank the value.
Using an HCM connection won't work.
08/16/2024 04:59 AM
@Roua If you have already handled it scenario via preprocessor you don't need to have a seperate user update rule
It will automatically update the customproperty 6 value to null(if it doesn't try '' only)
And then create a update account task for AD application and AD prov job while take care of it.
08/16/2024 05:08 AM - edited 08/16/2024 05:08 AM
so you basically you mean to make remove the value of any attribute i should connect it to saviynt for saviynt connection?
for example another case:
Mapping something from HCM/AD to a certain CP for example CP2 and then changing the mapping to CP3
CP2 will still hold the same value even if CP3 is updated after running the job? because i also encountered this, there is no way for it to just be empty since we removed CP2 from the mapping for example?
another question could you please explain to me the concept of the update via login update user task ?
since it created a task, how can i let this task be resolved? not manually but through running JOBS just like i run for example provisioning Job for AD and task is resolved how does it work for this user update task ? it is a bit unclear for me? and although the AD and LDAP task was resolved the update user task is still unresolved.
another thing, basically removing the value OR assigning the value of customproperty 6 the pause start date must be by creating a saviynt for saviynt connector ?
Thank you so much for your time and explaining
08/16/2024 06:28 AM - edited 08/16/2024 06:29 AM
08/16/2024 05:20 AM - edited 08/16/2024 05:20 AM
@Roua ,
1) changing mapping will not make the old property empty you have to explicitly pass null or empty value.
2) to complete a user update task ... Create a prov job choose tasktype as user update and nothing else.
3) you can do it via preprocessor or via user update rule by using saviynt for saviynt rest connection.
08/19/2024 02:31 AM
Hello @rushikeshvartak , @NM ,
Thank you so much for your explanation.
Here’s what I’ve understood, please correct me if I'm wrong:
- If I change the value of a custom property (CP) to a different CP, I need to clear the old CP value manually or only by using a Sav-to-Sav connector. therefore it is not automatically done by saviynt.
- In my case, if I want the "Paused Start Date" to be empty, I could use a Sav-to-Sav connector along with a user update rule. However, since I'm not using a Sav-to-Sav connector, I don’t need a user update rule. Instead, I am clearing the value directly from the preprocessor in the HCM and AD connections:
In updateuserjson (AD):
"customproperty6": "${if(user.customproperty5 == 'P' || user.customproperty5 == 'I'){''} else {user.customproperty6}}",
In MODIFYUSERDATAJSON (HCM):
"UPDATE NEWUSERDATA NU SET NU.customproperty6 = NULL WHERE NU.customproperty5 IN ('P', 'I')",
And this should be sufficient to clear the value of customproperty6.
- Finally, to process a user update task, I need to create a wsretry job with the task type set as "update user."
i created the job and the results are:
they failed but i couldn't find any error message nor in the logs..
it is correct that there are 4 pending tasks :
08/19/2024 02:36 AM
If I change the value of a custom property (CP) to a different CP, I need to clear the old CP value manually or only by using a Sav-to-Sav connector. Therefore, it is not automatically done by Saviynt.
In my case, if I want the "Paused Start Date" to be empty, I could use a Sav-to-Sav connector along with a user update rule. However, since I'm not using a Sav-to-Sav connector, I don’t need a user update rule. Instead, I am clearing the value directly from the preprocessor in the HCM and AD connections:
08/19/2024 03:50 AM - edited 08/19/2024 04:33 AM
thank you for your answe @rushikeshvartak ,
MODIFYUSERDATAJSON HCM connection
UPDATEUSERJSON:
this is Handling two requirements:
When the HCM-Status is I the Paused Started Date (customproperty6) is set and not cleared.
and
HCM Status is set to 'P' -> Identity is set to status 'Active' -> The users.CUSTOMPROPERTY6 contains todays date -> All accounts are disabled.
08/23/2024 01:41 AM
@NM ,
hello, no matter what kind of UPDATE USER TASK is created nothing it won't be completed with the following job, do you have any idea why? or what am i missing in the process?
08/23/2024 01:43 AM - edited 08/23/2024 01:43 AM
Hi @Roua click show more options under task type select update user.
08/23/2024 01:46 AM - edited 08/23/2024 01:47 AM
08/23/2024 01:49 AM
@Roua in the wsretry job you will see an option show more options after clicking on that select task type update user.
08/23/2024 01:58 AM
@NM , sorry i thought the screenshot was attached:
yes i do have it like this and still it doesn't update and user tasks that's the problem!
08/23/2024 02:01 AM
@Roua can you share you user update json?
08/23/2024 02:13 AM
update user json in HCM connection:
{
"customproperty6": "${if(user.customproperty5 == 'P' && user.statuskey == 1){currentDate} else if(user.customproperty5 == 'I'){user.customproperty6} else {''}}"
}
but not only regarding this conditions any user rule that will create update user task, the task won't be resolved
08/23/2024 02:21 AM
@Roua not the right json.
try this
{
"actions": {
"Update Login": {
"call": [
{
"name": "call1",
"connection": "userAuth",
"url": "",
"httpMethod": "POST",
"httpParams": "{\"lastname\":\"${user.lastname}\"}",
"httpHeaders": {
"Authorization": "${access_token}"
},
"httpContentType": "application/json",
"successResponses": [
200
]
}
]
}
}
}
08/23/2024 02:48 AM - edited 08/23/2024 02:49 AM
@NM thank you so much for your help, but i tried it it didn't work
here are the logs i found:
"i tried to search using th jobID i didn't find anything"
08/23/2024 02:51 AM - edited 08/23/2024 02:53 AM
@Roua do you see any error in prov comments ?
And is it working from postman?
Do you see number of tries increasing?
08/23/2024 03:04 AM
no errors in prov comments or in the task
i don't have access to postman right now i need some time Sorry
08/23/2024 03:15 AM
@Roua just try to update a customproperty with a dummy value to check if connection is working .
Do check the URL and connection name matching with connection json name.
08/23/2024 04:36 AM - edited 08/23/2024 04:38 AM
08/23/2024 05:38 AM
@NM,
thank you.
i tried as you said i created a test user update rule :
If Users.Custom Property 44 is updated
Then
(Create Update User Task [Connection: SAP HCM , Object: Update Login ])
and then i updated the cp44 and the task was created, so i run the job and still it didn't work
and yes i made sure of the connection name and the url
08/23/2024 05:40 AM
@NM i got the following provisioning comment :
Provisioning Comments
08/23/2024 05:41 AM - edited 08/23/2024 05:42 AM
08/28/2024 07:08 AM
Thank you all for you answer and recommendations, as it was mentioned, i completed it using sav4asv connection like the following:
ImportUserJSON:
{
"connection": "acctAuth",
"successResponses": {
"statusCode": [
200,
201,
202,
203,
204,
205
]
},
"url": "xxxxxxxxxxxxxxxxxxxxxx",
"httpMethod": "GET",
"httpHeaders": {
"Authorization": "${access_token}",
"Accept": "application/json"
},
"httpContentType": "application/json",
"userResponsePath": "results",
"colsToPropsMap":{
"username": "username~#~char",
"customproperty6": "customproperty6~#~char"
} ,
}
MODIFYUSERDATAJSON:
{
"ADDITIONALTABLES": {
"USERS": "SELECT customproperty5, customproperty6, customproperty48, USERNAME FROM USERS"
},
"COMPUTEDCOLUMNS": [
"customproperty6"
],
"PREPROCESSQUERIES": [
"UPDATE NEWUSERDATA SET customproperty6 = (SELECT customproperty48 FROM CURRENTUSERS WHERE NEWUSERDATA.USERNAME = CURRENTUSERS.USERNAME AND CURRENTUSERS.customproperty5 = 'P') WHERE EXISTS (SELECT 1 FROM CURRENTUSERS WHERE NEWUSERDATA.USERNAME = CURRENTUSERS.USERNAME AND CURRENTUSERS.customproperty5 = 'P')",
"UPDATE NEWUSERDATA SET customproperty6 = NULL WHERE EXISTS (SELECT 1 FROM CURRENTUSERS WHERE NEWUSERDATA.USERNAME = CURRENTUSERS.USERNAME AND CURRENTUSERS.customproperty5 <> 'P')"
]
}