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

ADSI - Create Account JSON

sab2
Regular Contributor
Regular Contributor

Hi,

I am working on the ADSI account creation json. I am trying to set the attribute 'displayname'. The logic behind it is, if the user has middlename then the displayname should be lastname, firstname, middlename. 

If the user does not have a middlename, then the logic is just, lastname, firstname.

I tried variations of the below line. Does anyone have any syntax recommendations that maybe I am missing? Thank You!!!

Line:  "displayName": "${if ({user.middlename} != null) {user.lastname} {user.firstname} {user.middlename} else {user.lastname} {user.firstname}}"

"displayName": "${if ({user.middlename} != null) '{user.lastname} {user.firstname} {user.middlename}' else '{user.lastname} {user.firstname}'}"

2 REPLIES 2

Ishan
Saviynt Employee
Saviynt Employee

You can try this:

"displayName":"${(user.lastname+', '+user.firstname+ (user.middlename!=null?(' '+user.middlename):''))}

 

Ishan Kamat
Technical Architect, Professional Services
SaviyntLogo.png

sab2
Regular Contributor
Regular Contributor

That worked! Thanks so much!