Symptom
User is getting the error message "[COE0019]Failed to retrieve result with given criteria" while filtering on the Internal Status of an offer via OData API.
Environment
SAP SuccessFactors Recruiting Management
Reproducing the Issue
Run the below query in Postman or in a Web browser (It could be for any data center. In this case I have taken DC15 as an example):
https://api15.sapsf.cn:443/odata/v2/JobOffer?$filter=internalStatus eq 'Completed'
Cause
Offer Letter Status Text (Highlighted in Yellow) is not recognized by the system while filtering on a status. Instead, the system is expecting a numerical value.
Resolution
Run the query by applying a numerical filter on the InternalStatus Code. For example: https://api15.sapsf.cn/odata/v2/JobOffer?$filter=internalStatus eq 2
Below are the InternalStatus codes for all the possible statuses:
- DRAFT-0
- PENDING-1
- COMPLETED-2
- REJECTED-3
- CANCELLED-4
Keywords
JobOffer , KBA , LOD-SF-RCM-API , Webservices & APIs , How To