In this document we shall discuss the successorNav field, from the Position Entity, in the context of an OData API GET Request.
OData APIs from Succession enable customers to build custom extensions on standard SuccessFactors application Succession Planning. The most common need for customers is the ability to create alternate visualizations on top of the succession data.
In certain use-cases, customers may wish to apply a filter on the successorNav field - e.g. successorNav/status eq 1. The requirement is to just return the status 1 employees. However, this is returning employees with status equal to 3.
- Integration Center
Reproducing the Issue
- Enter a sample GET query in Postman or Integration Center:
https://apisalesdemoXX.successfactors.com/odata/v2/Position?$select=code,effectiveStartDate,company,createdDate,successorNav/status&$expand=successorNav&$filter=successorNav/status eq 1&$orderby=code,effectiveStartDate
- View the result - employees with status not equal to 1 are being returned:
<link rel="edit" title="Successor" href="Successor(XXXX)"></link>
<category term="SFOData.Successor" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme"></category>
- This behavior is as designed, $filter cannot filter the value in the expand navigation.
- In this case, there are statuses equal to 1 and 3 in the expand Nav, all successor will be returned not only status eq 1.
- Expected Behavior:
In Odata v2 service the filter option works only at root entity level. It does not work on expanded entities
- Raise an Enhancement Request:
If having this feature is important for your company, we kindly ask you submit an Enhancement Request on the community.
We welcome inputs from customers to improve the functionality of our products.
All enhancement requests are reviewed by our Product Management team and, if successful, are developed and implemented in a future product release.
Details on this here:
2281168 - How to create Enhancement Request for Successfactors Integrations