SAP Knowledge Base Article - Public

3436023 - OData API query returning inactive employees even without using filter status in t,f - SuccessFactors OData API


You noticed your API query is returning data for inactive employees even though you are not using the filter "status in t,f". 

Image/data in this KBA is from SAP internal systems, sample data, or demo systems. Any resemblance to real data is purely coincidental.


  • SAP SuccessFactors HXM Suite

    • OData API

Reproducing the Issue

  1. Run a query similar to this:'cgrant')?$select=userId,firstName,lastName&$format=json
  2. Assuming employee "cgrant" is inactive, and since no status has been informed in the filters, no data should return on the response. 
  3. Response is returned normally, as below: 
"userId": "cgrant",
"firstName": "xxxxxx",
"lastName": "xxxxxxx",
"displayName": "cgrant"


API query using Key Predicate, hence it will query the database for all statuses.


As explained in the OData Reference Guide, it works like this: 

Querying users by key predicate

When a key predicate is used, the query will return the matching entry regardless of user status. Below is an example of querying a user by key predicate:

Please note: If you expand from a key predicate, you will only get expanded users in status t and T.

See Also

Querying Different Types of Users | SAP Help Portal

Query with Key Predicate | SAP Help Portal


inactive employees, status, User, active employees, key predicate, status 't,f', external employees. , KBA , LOD-SF-INT-ODATA , OData API Framework , Problem


SAP SuccessFactors HCM all versions


Pasted image.png