Click HERE to see how Saviynt Intelligence is transforming the industry. |
08/13/2024 02:20 AM
Hi Team,
we have a requirement where if cp56 and cp57 both have some value then only CP57 value gets pushed to AD, else if only CP56 has some value and CP57 is null then send the value of CP56 to AD. In case bothe CP56 and CP57 is null then push null value to AD.
We tried below expressions,
"msExchExtensionAttribute24": "${if(user?.customproperty57!=null && user?.customproperty56!=null){user.customproperty57} else {user.customproperty56}}",
"msExchExtensionAttribute24": "${if(user?.customproperty57!=null && user?.customproperty56!=null){user.customproperty57} else if(user?.customproperty57==null && user?.customproperty56!=null){user.customproperty56} else{''}}",
"msExchExtensionAttribute24": "${if(user?.customproperty56!=null){if(user?.customproperty57!=null){user.customproperty57} else {user.customproperty56}}else{''}}"
"msExchExtensionAttribute24": "${user?.customproperty57 != null && user?.customproperty56 != null ? user.customproperty57 : (user?.customproperty56 != null && user?.customproperty57 == null ? user.customproperty56 : null)}",
However, in all the cases, we noticed that if only CP56 is updated and CP57 is null, then that CP56 value is not pushed to AD.
Request you to please provide some suggestion
08/13/2024 03:09 AM
@Rashmi try this
${if((user?.customproperty57==null) && (user?.customproperty56==null)){''} else if((user?.customproperty57==null) && (user?.customproperty56!='')){user.customproperty56} else{user.custompropety57}}"
08/13/2024 06:04 AM
"msExchExtensionAttribute24": "${user?.customproperty56 != null && user?.customproperty57 == null ? user.customproperty56 : (user?.customproperty57 != null ? user.customproperty57 : null)}"
08/14/2024 01:28 AM
Hi ,
Upon using "msExchExtensionAttribute24": "${user?.customproperty56 != null && user?.customproperty57 == null ? user.customproperty56 : (user?.customproperty57 != null ? user.customproperty57 : null)}" .
We are getting the below error in the provisioning comments.
{"call1":{"headers":null,"message":{"error":{"message":"No Record found","detail":"Record doesn't exist or ACL restricts the record retrieval"},"status":"failure"},"statusCode":404,"description":null,"status":"Failed"}}
08/14/2024 01:31 AM
Does service account have permission to make attribute change?
Try once with a static value.
08/14/2024 01:59 AM
Hi,
Yes the service account has the permission to make attribute change. Also when we are updating the custom property via UI, the pending task is getting completed without any errors.
08/14/2024 05:37 AM
"msExchExtensionAttribute24": "${user?.customproperty57 != null ? user.customproperty57 : (user?.customproperty56 != null ? user.customproperty56 : null)}"
08/20/2024 02:36 AM
Hi,
Upon trying "msExchExtensionAttribute24": "${user?.customproperty57 != null ? user.customproperty57 : (user?.customproperty56 != null ? user.customproperty56 : null)}", we are Getting the below error in the provisioning comments.
Error while Update operation for account-H286693 in AD - Error parsing JSON
08/20/2024 06:22 AM
Please share full json & logs in text file
"msExchExtensionAttribute24": "${user.customproperty57 != null ? user.customproperty57 : (user.customproperty56 != null ? user.customproperty56 : 'default_value')}"