Skip to Content
avatar image
Former Member

Can any one help me on $batch issue for creating multiple records (POST)

I have to create records for multiple entries in to table using $batch operations

I created every thing and trying to execute but I am not able to get the result. I tried to debug by placing external break point, but the break point is not triggering.

I have given the URI /sap/opu/odata/sap/XXXXXX/$batch

the request body content as

--batch
Content-Type: multipart/mixed; boundary=batch


--changeset
Content-Type: application/http
Content-Transfer-Encoding: binary

POST AttachmentSet HTTP/1.1
Content-Type: application/jsonxml
Content-Length: 1000

{"TicketItem": "XXXX1001010","PermissionCatalog":"12","SizeBytes": "462","FileLocation": "XXX/2017/07/md5.jpeg","FileName": "blocks.jpeg","ContentType": "image/jpeg"
}

--changeset
Content-Type: application/http
Content-Transfer-Encoding: binary


POST AttachmentSet HTTP/1.1
Content-Type: application/jsonxml
Content-Length: 1000

{"TicketItem": "XXXX001010","SizeBytes": "3000","FileLocation": "XXXX/2017/07/md1.jpeg","FileName": "test.jpeg","ContentType": "image/jpeg"
}

--changeset--
--batch--

When I am trying to execute I got the result as shown,

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Jul 13, 2017 at 05:48 AM

    Thanks problem resolved

    Add comment
    10|10000 characters needed characters exceeded