Symptom
PATCH method for the API - API_PURCHASECONTRACT_PROCESS_SRV
You would like to use the purchase contract API to update item condition values
but in the patch operation is not supported for conditions.
"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 S/4HANA Cloud
Cause
PATCH as a method is not available for this API
Resolution
For this API you can however execute a PATCH within a BATCH operation
Sample:
Request URI: /sap/opu/odata/sap/API_PURCHASECONTRACT_PROCESS_SRV;v=2/$batch
--batch
Content-Type: multipart/mixed; boundary=changeset
--changeset
Content-Type: application/http
Content-Transfer-Encoding: binary
PATCH A_PurContrItmCndnAmount(PurchaseContract='46000XXXXX',PurchaseContractItem='00010',ConditionValidityEndDate=datetime'9999-12-31T00%3A00%3A00',ConditionRecord='000011XXX3',ConditionSequentialNumber='01') HTTP/1.1
Content-Type: application/json
{
"ConditionRateValue": "95.00"
}
--changeset--
--batch--
Keywords
PATCH, API_PURCHASECONTRACT_PROCESS_SRV, item conditions, S4PC , KBA , MM-FIO-PUR-SQ-CON , Fiori UI for Manage Purchase Contracts , Problem