Matthew Woods
Posts: 0
Joined: Wed Feb 26, 2014 11:08 pm

400 Bad Request DBSP260

Object must be present in the request body

I have no idea what this means. Please help. I am so close to finishing this app.

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

400 Bad Request DBSP260

Hello Matthew,

Where exactly do you get this error?
Please tell us more details. Provide screen shots..

Matthew Woods
Posts: 0
Joined: Wed Feb 26, 2014 11:08 pm

400 Bad Request DBSP260

Image

It happens when I test the update service. I was stumped on why my app wasn't updating when it seemed like I was doing nothing wrong until I tested it and it spits out this error.

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

400 Bad Request DBSP260

Dear Matthew.

You have missed the "object_id" parameter.
So you should fill it as db service need to know what object should be updated.
Please see the screenshot for details.

Image

Matthew Woods
Posts: 0
Joined: Wed Feb 26, 2014 11:08 pm

400 Bad Request DBSP260

Image Image
Image

I have object id mapped to the id spot (screenshot 1). I need to have it update the items in the table (screenshot 2) depending on how they show up instead of updating a specific item. My app currently looks like screenshot 3 but will not update because of this error. I am new to the cloud and networking in general so I'm probably missing something really simple but if I put in a specific id like your above screenshot won't it only update a single item in the database?

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

400 Bad Request DBSP260

Matthew,

Update service makes changes only to single object (specified by object_id parameter) in the database.

So if you want to update a few objects, there are two ways:

  1. Run update service for each object you have to change in DB.

  2. Implement custom save serverside code which could recieve collections of items to update.

    Please take a look at this doc http://docs.appery.io/documentation/b...

    Also you need to know how to invoke service from javascript. This topic will help https://getsatisfaction.com/apperyio/...

Return to “Issues”