cancel
Showing results for 
Search instead for 
Did you mean: 

SAP CPI: State of the resource (entity) was already changed (If-Match) . OData error .

amit777
Participant
0 Kudos

Hi Experts,

We are trying to achieve a PATCH operation on Odata for price condition records in S4.

API we are using is : /sap/opu/odata/sap/API_SLSPRICINGCONDITIONRECORD_SRV

We made sure to READ first the condition record and extract and set etag in header If-Match, with Header request and response in channel set to *.

But still we keep getting the same error - State of the resource (entity) was already changed (If-Match)

Precondition Failed : 412 :HTTP/1.1

We have checked and verified that all setting are proper. Need help with this issue. Has anyone faced this issue? How was it solved.

Accepted Solutions (0)

Answers (2)

Answers (2)

Sriprasadsbhat
Active Contributor
0 Kudos

Hello Dilip,

Please follow below tag and it might help you.

https://blogs.sap.com/2018/09/16/sap-cloud-platform-integration-odata-v2-conditional-update/

Regards,

Sriprasad

Sriprasadsbhat
Active Contributor
0 Kudos

Hello Dileep,

Have you added this header as part of request headers section in OData Receiver channel.

Regards,

Sriprasad Shivaram Bhat

amit777
Participant
0 Kudos

Hi sriprasad.shivarambhat

Yes I have set value '*' in that so that it takes all the header including If-Match and could see in the channel trace also that the If-Match and etag has same values.