cancel
Showing results for 
Search instead for 
Did you mean: 

DPC_EXT SIMPLE CODE TO UNDERSTAND THE INPUT PARAMETER IN ODATA SERVICES TO FILTER.

0 Kudos

Hi ,

I am new to ABAP GATEWAY SERVICES , I want to understand it with a simple example through DPT_EXT coding.

so that how can I filter through input parameters the entity and entity_set and what actually these term's mean.

can anyone help me with simple and good example of explanation.

Thanks in Advance.

Accepted Solutions (0)

Answers (1)

Answers (1)

AshwinDutt
Active Contributor
0 Kudos

Hello Ajay,

Please have a look at the below which will describe the implementation of all the basic operations in detail

Regards,

Ashwin

0 Kudos

Hi Ashwin ,

Thanks for the link.

I went through this document everything is fine, But what I'm looking for is how to pass input parameter without keys. but here we are using "it_key_tab" for input parameters .and also here it is for DDIC structure. but here in my scenario I am calling a function module from other system through RFC and then creating gateway services . the main thing what I want to know is how to give input parameters without using keys as input parameters in entityset.

for example : I want to filter spfli based on cityfrom and cityto which are not defined as keys. so for me these should be input parameters will it be possible?

Thanks in Advance.

AshwinDutt
Active Contributor
0 Kudos

Yes even tough they are not defined as Keys in your GW Model you can send CityFrom and CityTo as inputs as part of filter parameters.These parameters will be filled inside IT_FILTER_SELECT_OPTIONS.


Using this we can pass inputs to the logic which will filter data based on CityFrom and CityTo

Sample URL ->

/sap/opu/odata/SAP/ZTest_SRV/CarrierSet?$filter=CityFrom eq 'A1' and CityTo eq 'A2'

0 Kudos

Thank you so much Ashwin

I understood the logic what you have said .yesterday I tried a lot by googling it out but can't understand where I am missing the logic. Can you please help by giving any sample code step by step through which I  can break it. for example like how to define filters in dtc_ext with respect to IT_FILTER_SELECT_OPTIONS with simple example.

Thanks in Advance

AshwinDutt
Active Contributor
0 Kudos

Please have a look at the below for the details ->