cancel
Showing results for 
Search instead for 
Did you mean: 

Error : Method PUT not allowed for ENTITY.COLLECTION

Ranjith
Participant
0 Kudos

Hi All,

When I try to update a record in my service, I get the “Method PUT not allowed for ENTITY.COLLECTION”. Same goes for PATCH, DELETE.

gregorw
Active Contributor

Can you replicate this issue in the standard Bookshop example?

Ranjith
Participant
0 Kudos

Hi Gregor Wolf,

As you have asked i'm facing same problem in the standard Bookshop example.

ThorstenHoefer
Active Contributor

Accepted Solutions (1)

Accepted Solutions (1)

Ranjith
Participant

Hi Gregor Wolf,

Issue Solved.

Just passed my key in the URL instead of content.

http://localhost:4004/executive/accounts/1000000000001200
acmebcn
Participant

Thx for sharing solution! I was going bananas with the same problem than you!!

Ahmedkhan29789
Participant
0 Kudos

Hi ranjith13119-gmail.com @gregor.wolf

I am also facing same problem, But I have more than one keys, Can you please share some exmaple how to pass multiple keys, And important question, Is it mandatory to pass all keys when we have to do update operations?

Sab
Explorer
0 Kudos

Hi Ahmed,

Its an old post and am sure you might have had the answer to your questions. But for the sake of others with same scenario.

We should be passing all the key field values in the URL.

E,g - Approvers(ID=f20234f6-07e9-4574-ae85-5a6652c31758,PLANT='TEST',APPR_LEVEL='1',APPR_ID='SABTEST')

Texts in BOLD are my key field values

Answers (1)

Answers (1)

gregorw
Active Contributor
0 Kudos

A PUT works only on an entity. You should try /browse/Books(450).