cancel
Showing results for 
Search instead for 
Did you mean: 

No response from Batch during Query Operation

AshwinDutt
Active Contributor
0 Kudos

Hello Experts,


I am Performing a Batch Operation to Query as described below.

But i am unable to see the content in the response.


I have followed the standard way to implement Batch operation as per suggested by Gateway experts in this forum.

Still i am unable to get the content in the response of the batch.


I Kindly request all Gateway experts to provide your valuable inputs to resolve this issue and suggest/guide me if anything is wrong from my side so that i can correct.


The below are the details :


Both /IWBEP/IF_MGW_APPL_SRV_RUNTIME~CHANGESET_BEGIN & /IWBEP/IF_MGW_APPL_SRV_RUNTIME~CHANGESET_END are redefined.


METHOD -


URL -

http://********/sap/opu/odata/sap/<; My Service Name >/$batch

HEADER -

Authorization: SAP ID & PASSWORD

x-csrf-token:   Enter Token

Content-Type: multipart/mixed; boundary=batch


BODY -


​--batch

Content-Type: application/http

Content-Transfer-Encoding: binary

Accept: application/json

GET get_rec_types1?$filter=ImWhttype eq 'XX' and ImCountry eq 'IN' HTTP/1.1

--batch

Content-Type: application/http

Content-Transfer-Encoding: binary

Accept: application/json

GET get_rec_types1?$filter=ImWhttype eq 'XX' and ImCountry eq 'IN' HTTP/1.1

--batch--​

RESPONSE -

RESPONSR BODY -

Thanks & Regards,

Ashwin

View Entire Topic
AshwinDutt
Active Contributor
0 Kudos

Hello Arun,

I also noticed that 400 Bad Request comes only when i apply filters.

With out filters data is coming ( i.e., entity collection ).

Regards,

Ashwin

arunchembra1
Participant
0 Kudos

Hi Ashwin,

Can you try like this

GET get_rec_types1?$filter=(ImWhttype eq 'XX' and ImCountry eq 'IN') HTTP/1.1


Thanks,

Arun

AshwinDutt
Active Contributor
0 Kudos

Hello Arun,

I tried with GET get_rec_types1?$filter=(ImWhttype eq 'XX' and ImCountry eq 'IN') HTTP/1.1

I am getting below error Arun

Regards,

Ashwin

Former Member
0 Kudos

Hi Ashwin,

The error is coming because in BATCH READ operation, while passing the $filter the format is:

GET get_rec_types1/?$filter=ImWhttype+eq+'XX'+and+ImCountry+eq+'IN' HTTP/1.1

Replace all spaces with a '+' sign. It should work fine.

Regards,

Aashika

AshwinDutt
Active Contributor
0 Kudos

Hello Aashika,

Yes i have already figured out that

Thanks for your kind response.

Regards,

Ashwin