Symptom
You have a business scenario where you need to upload data to the Work Permit portlet via OData API query.
In the Manage Business Configuration, you set the country field to “Mandatory: No”
After you run the OData query, you still notice the error:
<message lang="en-US">ChangeSet index 1 - country is a required field and cannot be blank. Failed record info: XXXX for Key XXXXX with the index 0</message></error>
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
- Manage Business Configuration
Reproducing the Issue
Run the query:
https://XXXXXX/odata/v2/EmpWorkPermit
Notice the above mentioned error
Resolution
This is an expected behaviour and as per our standard documentation country field is a part of the business key and it cannot be empty.
For our standard guide reference, please go to “See also” section
See Also
SAP SuccessFactors Employee Central OData API: Reference Guide (V2)
https://help.sap.com/doc/7efdca36492e47c7b20ab92c4ca6323c/2205/en-US/SF_EC_OData_API_REF.pdf
2834986 - ChangeSet index 3 - gender is a required field and cannot be blank - SAP SuccessFactors
https://userapps.support.sap.com/sap/support/knowledge/en/2834986
2942505 - XXX is a required field and cannot be blank : error is getting thrown during EmpJob OData API Upsert
https://launchpad.support.sap.com/#/notes/2942505
Keywords
country is a required field and cannot be blank, workPermitInfo, Manage Business Configuration , KBA , LOD-SF-INT-ODATA , OData API Framework , LOD-SF-INT , Integrations , LOD-SF-INT-API , API & Adhoc API Framework , Problem