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

Displayname splitting in updateaccountJSON or createaccountJSON

Harsha
Regular Contributor II
Regular Contributor II

Hi,

We had a requirement to split the displayname in Updateaccountjson as well as createaccountjson,if displayname contains = then remove it and uppercase the right side of string

For ex: Displayname: Esha=Dutta

Output in the AD should be  Esha DUTTA

How this can be achieved?

Note: We are not doing this in while importing because we are using schema import for this HR source,it already has performance issue.

I tried below ways Updateaccountjson but it is throwing no signature of method error:

"displayName":"${user.customproperty30.equals('SAPSF') ? user.lastname.toString().toUpperCase() +' ' + user.firstname : (user.customproperty30.equals('SAPHR') && (user.displayname==null || user.displayname.equals(''))) ? user.firstname+' '+user.lastname.toString().toUpperCase() :(user.customproperty30.equals('SAPHR') && (user.displayname!=null || user.displayname!='' && (user.displayname.contains('=')))) ? substringAfter(user.displayname,'=').toUpperCase() : (user.customproperty30.equals('SAPHR') && (user.displayname!=null || user.displayname!=(''))) ? user.displayname : user.displayname}"

And also used this

SUBSTRING_INDEX(displayname, '=', -1).toUpperCase()

Please help me how we can split the displayname.

 

Thanks,

Harsha

4 REPLIES 4

rushikeshvartak
All-Star
All-Star
user.displayname.substring(0, user.displayname.indexOf("="))

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

Harsha
Regular Contributor II
Regular Contributor II

Hello @rushikeshvartak ,

Thank you for the quick response, above mentioned logic will remove part that comes next to =. I just want to replace = with space and uppercase right side part.  

Thanks,

Harsha

 

Example


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

Harsha
Regular Contributor II
Regular Contributor II

Hello  @rushikeshvartak ,

Ex: If it comes from Source as Displayname: Alessandro=Di Bianchi

transformed  displayname: Alessandro DI BIANCHI

Thanks,

Harsha