cancel
Showing results for 
Search instead for 
Did you mean: 

How to extract history/previous data in SF Odata query

former_member277492
Participant
0 Kudos

Hello Experts,

I am working on an Integration between SF and CPI.

I am working on Benefits and Compensation portlets where the requirement is to compare 2 values (previous and current) and then populate the effective start date.

Ex: Paycompvalue and Paycompvalue previous to be compared and in case of any change exist then we should populate the effective start date.

And, In this case I am not getting the previous values in the Employee record. Not sure where am I missing.

This I have implemented in Soap protocol in Compound Employee API for Delta load.

Any insight would be appreciated.

Thanks,

Best Regards,

Sree

Accepted Solutions (0)

Answers (3)

Answers (3)

former_member277492
Participant
0 Kudos

Hello Vermeer,

Thank you for the revert.

I have tried with the said parameters and it's not working in odata and working in Compound Employee.

Hello Shivaram,

Thank you for the information provided.

I am working on multiple templates as Benefits, Pension, Deduction and etc. I have tried it with CE as well and not getting the desired output.

Hence, we are trying to incorporate Benefits, Pension and Deduction portlets into Compound Employee API and test the scenarios.

Will there be any implications of Implementing these portlets in Compound employee API?

Thank you,

Best Regards,

Sree

Sriprasadsbhat
Active Contributor
0 Kudos

Hello Sreekar,

SuccessFactors OData APIs doesnt support field level delta as it works with Compound Employee ( SOAP ). Possible option would be using fromDate and toDate .Using these two parameters you would be able to retireve history ( hopefully with Sequence Numbers to identify latest records ) and then wite Groovy or XSLT to have desired current and previuous value.

https://apps.support.sap.com/sap/support/knowledge/en/2528499

Other option would be using Compound Employee and using required parameters to get PayCompRecurring and payCompNonRecurring records.Refer below for CE.

https://apps.support.sap.com/sap/support/knowledge/en/2907161

Regards,

Sriprasad Shivaram Bhat

IvoVermeer
Explorer
0 Kudos

Hi Sreekar,

To see those fields, you have to:

  • Run a query in delta mode ( queryMode=delta )
  • include resultOptions=renderPreviousTags to render seperate _previous fields
    This will give you extra ..._previous> fields for almost every field in the xml. Be aware, these are not part of the xsd that the connector creates for you

Please also refer to the documentation on this:

https://help.sap.com/viewer/5bb9a5b997a843c88e769a105e4af4d4/LATEST/en-US/c62e316c1eff4b95b60aae5855...

If you need a real-world example, please let us know 👍