Symptom
You wish to know how you can use OData API to delete a record from an EC entity.
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 HCM Suite
- OData API
Resolution
When we use OData API to delete records, we can use the following:
- Parameter PurgeType=full (in this case a record is deleted and replaced with new data sent in the payload)
- If your EC entity has the field "operation" inside the OData API Data Dictionary, we can do a simple UPSERT with "operation": "DELETE" (This deletes records and leaves the entity/table empty and also deletes from the database/UI)
Example of operation field from Data Dictionary (Entity PerPhone)
Example image from API payload with "operation": "DELETE" and Response from Postman (Entity PerPhone)
See Also
Keywords
DELETE, OData API, Purge, Delete Record , KBA , LOD-SF-INT-ODATA , OData API Framework , LOD-SF-INT , Integrations , How To
Product
SAP SuccessFactors HCM Suite all versions
Attachments
image.png |
image.png |