SAP Knowledge Base Article - Public

2437595 - Odata PerPerson entity's standard field throws the error "personIdExternal is not viewable"

Symptom

You are trying to fetch data via Odata API PerPerson entity and it returns the below error:
PerPerson/personIdExternal is not viewable

         

Environment

Successfactors Odata API

Reproducing the Issue

Odata API Request

/odata/v2/PerPerson?$format=json&$select=lastModifiedDateTime,personIdExternal,createdBy,lastModifiedBy,dateOfBirth,createdOn,lastModifiedOn&$top=50

Odata API Response

{
"error" : {
"code" : "COE_BAD_PROPERTY_EXPRESSION", "message" : {
"lang" : "en-US", "value" : "Bad property expression: PerPerson/personIdExternal; PerPerson/personIdExternal is not viewable"
}
}
}

Cause

It is due to the configuration overridden from the succession data model.

Data model shows

<hris-field max-length="32" id="person-id-external" visibility="none"> 

dm.jpg

Due to this, Odata API data dictionary shows "selectable=false"

dd.jpg

Resolution

Change the configuration in succession data model (You may have to involve your implementation partner to do this)

such that the visibility is changed to "both" that it looks like the below - 

<hris-field max-length="32" id="person-id-external" visibility="both"> 

Please perform an Odata metadata refresh after this change.

Keywords

personIdExternal is not viewable
, KBA , LOD-SF-INT-API , SF API & Adhoc API Framework , Problem

Product

SAP SuccessFactors HCM Core all versions