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

Need help in SAP SuccessFactor ImportUser Mapping

Jaya
Regular Contributor II
Regular Contributor II

Hi All,

I need help in mapping nested & multivalued attribute in ImportUserJson's colsToPropsMap

This is the query which I have taken from SAP SuccessFactor Connector Guide - https://saviynt.freshdesk.com/support/solutions/articles/43000478793-sap-successfactors-connector-gu...

Jaya_0-1675258675910.png

So when I use results[0] I am able to fetch results at the first place of solution array, but in our use case latest value is coming at the last place of result array and with this query 'empInfo/jobInfoNav/startDate+asc' we are not able to sort data with startdate(when data is updated), so my question is how to fetch value at last place of array.

NOTE: I have tried results[-1], results[-1:],results[length-1] but it doesn't work.

Please help.

Thanks,

Jaya

@Nikitaj @rushikeshvartak 

Thanks
Jaya Karothia
8 REPLIES 8

SB
Saviynt Employee
Saviynt Employee

Let me check this and will update.


Regards,
Sahil

Saathvik
All-Star
All-Star

Can you try this results[length()-1] or  results[size()-1]


Regards,
Saathvik
If this reply answered your question, please Accept As Solution and give Kudos to help others facing similar issue.

rushikeshvartak
All-Star
All-Star

"companyname": "empInfo.jobInfoNav.results[empInfo.jobInfoNav.results.size()-1].companyNav.name~#~char"


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

Jaya
Regular Contributor II
Regular Contributor II

Hi Sk/rushikesh,

I have tried all these 3 methods but I am getting value as Null.

Jaya_0-1675347078007.png

Jaya_2-1675347289852.png

Jaya_1-1675347090277.png

I have attached the logs for your reference.

 

Thanks,

Jaya

@Saathvik 

Thanks
Jaya Karothia

Try below 

empInfo.jobInfoNav.results[Integer.valueOf(String.valueOf(empInfo.jobInfoNav.results.size()-1))]


Regards,
Saathvik
If this reply answered your question, please Accept As Solution and give Kudos to help others facing similar issue.

Jaya
Regular Contributor II
Regular Contributor II

Still it's Null

PFA error message

Jaya_0-1675431966268.png

 

Thanks
Jaya Karothia

SB
Saviynt Employee
Saviynt Employee

Can you share a sample of the response text from Postman and the intended value we need to fetch.


Regards,
Sahil

"companyname": "empInfo.jobInfoNav.results[empInfo.jobInfoNav.length -1].companyNav.name~#~char"


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