Announcing the SAVIYNT KNOWLEDGE EXCHANGE unifying the Saviynt forums, documentation, training, and more in a single search tool across platforms. Click HERE to read the Announcement.

How to store two different attributes of source application in a single saviynt attribute

Jaya
Regular Contributor II
Regular Contributor II

Currently we are storing two different attributes(suppose firstname & lastname) from a source application to two different Saviynt custom attributes(CP49 & 50).

"customproperty49": "employmentNav.empJobRelationshipNav.results[0].relUserNav.firstName~#~char",
"customproperty50": "employmentNav.empJobRelationshipNav.results[0].relUserNav.lastName~#~char"

FYI - we have used REST connector for integration & these mapping are under 'colsToPropsMap' of ImportUserJSON.

So my query is how can I store these two different attributes in a single Saviynt attribute with space in between(For Ex- Firstname(space)lastname).

Thanks

Jaya Karothia

Thanks
Jaya Karothia
9 REPLIES 9

SB
Saviynt Employee
Saviynt Employee

You can use a format as below for this. Please ensure to update the response path depending on how your target app presents the data.

"displayName": "#CONST#${response.userKey != null? response.'firstname'+' '+ response.'lastname' : null}~#~char",


Regards,
Sahil

Jaya
Regular Contributor II
Regular Contributor II

Hi sahil,

Can you please help me to write this with below path-

currently we are using this in CP49 & 50

"customproperty49": "employmentNav.empJobRelationshipNav.results[0].relUserNav.firstName~#~char",


"customproperty50": "employmentNav.empJobRelationshipNav.results[0].relUserNav.lastName~#~char"

 

I tried it by writing it in this format but  i am getting syntax error msg

Thanks,

jaya

Thanks
Jaya Karothia

SB
Saviynt Employee
Saviynt Employee

Please share the format you used and also the response you get for the api call.


Regards,
Sahil

Jaya
Regular Contributor II
Regular Contributor II

PFA format & sample response.

Thanks
Jaya Karothia

SB
Saviynt Employee
Saviynt Employee

You can try with below and see if it works.

"#CONST#${response.'employmentNav.empJobRelationshipNav.results[0].relUserNav.firstName'+' '+ response.'employmentNav.empJobRelationshipNav.results[0].relUserNav.lastName' : null}~#~char"


Regards,
Sahil

Jaya
Regular Contributor II
Regular Contributor II

It is updating same query in the attribute not value. PFB Screenshot.

Jaya_0-1686565146108.png

 

Thanks
Jaya Karothia

"#CONST#${response.employmentNav.empJobRelationshipNav.results[0].relUserNav.firstName+' '+ response.employmentNav.empJobRelationshipNav.results[0].relUserNav.lastName : null}~#~char"


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

Jaya
Regular Contributor II
Regular Contributor II

Same problem now it is saviynt without single quotes -

Jaya_0-1686568290178.png

 

Thanks
Jaya Karothia

SB
Saviynt Employee
Saviynt Employee

Can you try with the below and see if it works. Also please confirm if you map just firstname, is it getting stored in the CP attribute?

"#CONST#${String data1 = employmentNav.empJobRelationshipNav.results[0].relUserNav.firstName; String data2 = employmentNav.empJobRelationshipNav.results[0].relUserNav.lastName; ret = data1 +' '+ data2; return ret}~#~char"


Regards,
Sahil