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

Retain AD Account Mail attribute value for specific users

mgandr
New Contributor III
New Contributor III

Hello,

We have a scenario wherein we'd like to exclude updating of AD Mail attribute value to some users.

For instance, if the user's username is 'ABCDEF', we wish to retain the current value assigned to "mail", allowing updates to the other AD attribute values. On the other hand, if the user?.username is not equal to 'ABCDEF', the "mail" attribute value will be constructed by concatenating user?.customproperty31 and the domain.

Is it feasible to achieve this within the UpdateAccountJSON, or is the exclusion limited to the Advanced Query (SQL) section of the Provisioning Job, where we would prevent the Update Account task for the user?

6 REPLIES 6

rushikeshvartak
All-Star
All-Star

You can update json with if else logic to retain

Sample Logic :

 

"Department":"${if((account.customproperty7 === null ? '' : account.customproperty7) === Department)(SAVIYNTNOTCHANGED) else (Department)}"


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

AmitM
Valued Contributor
Valued Contributor

Hi @mgandr ,

This forum can help - https://forums.saviynt.com/t5/identity-governance/dont-provision-a-specific-attribute-if-dynamic-att...

As your use case is also update account. SAVIYNTNOTCHANGED will work.

Thanks, Amit

mgandr
New Contributor III
New Contributor III

I've tried the below but it doesn't seem to work and I'm getting this error No such property: customproperty24 for class: java.lang.String

"mail": "${if(account?.customproperty24.contains('ABC.com'))(SAVIYNTNOTCHANGED) else {user?.customproperty31 + Domain}}"

validate if name is exposed

"mail": "${if(account?.name.contains('ABC.com'))(SAVIYNTNOTCHANGED) else {user?.customproperty31 + Domain}}"

or 

"mail": "${account?.customproperty24?.contains('ABC.com') ? 'SAVIYNTNOTCHANGED' : (user?.customproperty31 ?: '') + 'Domain'}"


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

It didn't work too. 

"mail": "${account?.customproperty24?.contains('ABC.com') ? 'SAVIYNTNOTCHANGED' : (user?.customproperty31 ?: '') + 'Domain'}"

Error: No such property: customproperty24 for class: java.lang.String

"mail": "${if(account?.name == 'abc.def')(SAVIYNTNOTCHANGED) else {user?.customproperty31 + Domain}}" 

Error: No such property: name for class: java.lang.String

"mail": "${if(user?.username == 'ABC')(SAVIYNTNOTCHANGED) else {user?.customproperty31 + Domain}}"

Error: No such property: SAVIYNTNOTCHANGED for class: SimpleTemplateScript43999

SAVIYNTNOTCHANGED  not works with SAP Connector only


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