AnsweredAssumed Answered

Retrieve more than one document from cache

Question asked by extern.kshirsagar_rupesh557429 on May 30, 2018
Latest reply on May 31, 2018 by britto.parthalomew

Hi,

 

I have one scenario, where one employee can hold multiple passports of different countries, that has be fetched from FOWorkPermit SuccessFactors.

But, those multiple passports are fetched in the form of multiple documents.

 

e.g 

Document 1:

<FOWorkPermit>

<userid>12</userid>

<doctype>IND_Passport</doctype>

<docnumber>1234</docnumber>

<country>IND</country>

</FOWorkPermit>

 

Document 2:

<FOWorkPermit>

<userid>12</userid>

<doctype>AUS_Passport</doctype>

<docnumber>6789</docnumber>

<country>AUS</country>

</FOWorkPermit>

 

..................and so on............

 

I am adding this documents into one cache.

When i try to retrieve this documents from cache in final map, i receive error as found more than one document in document cache.

 

How can i achieve above scenario, and have below expected output

 

firstname,lastname,userid,doctype,docnumber,country

abc,xyz,12,IND_Passport,1234,IND

abc,xyz,12,AUS_Passport,6789,AUS

 

 

**Note: firstname and lastname are from main profile.

Outcomes