Symptom
The error below is occurring in an upsert in Position object:
"The operation failed. The value 123 provided for field "department" is invalid.".
Image/data in this KBA is from SAP internal systems, sample data, or demo systems. Any resemblance to real data is purely coincidental.
Environment
- SAP SuccessFactors HXM Suite
- OData API
Cause
Department record provided in the Upsert payload doesn't have an active time-slice in the period provided for Position.
So if the effective start date for Department is later than Position, it will throw the error message.
Resolution
Make sure that the Department code provided in the Upsert is active at the effectiveStartDate time of the Position.
For example: if you provide effectiveStartDate equal to "2022-01-01" for Position, the Department record needs to have an active time-slice that covers this "2022-01-01" period. So if the Department record time-slices are these ones below:
- 2022-12-01
- 2023-01-01
The error occurs, because none of these two records cover the date "2022-01-01".
Keywords
timeslice, time slice, startdate, start date, effective, period, active, available, odata api, api, insert, operation failed , KBA , LOD-SF-INT-EC , Employee Central SFAPI & OData Entities , Problem