cancel
Showing results for 
Search instead for 
Did you mean: 

OData CDS, not in SEGW, and reusing old ABAP logic ?

rosenpetrov
Explorer
0 Kudos
137
  • SAP Managed Tags:

Hello colleagues,

Is there a way to create a new OData service with CDS view, to reuse in the service implementation an existing ABAP code and this to happen by not using transaction SEGW? AMDP is not an option because it does not allow execution of such old code as i know.

I would like to create an OData service by using a CDS view (let's sat newly created).
I would like also to reuse an existing logic which have already been written in ABAP code in lets say a soubroutine in include file. This subroutine would return a simple variable of type FLAG. And based on the value in this flag - different set of entries have to be passed as an OData result.
To reuse the existing logic i have to: perform sub in program using... 
Is this possible to happen when we use just a new CDS tech. (@odata.publish true) and NOT in transaction SEGW ( for SEGW is clear _DPC class allowes us to reuse such kind of logic) ?

*lets assume that there is some implemented algorithm in ABAP which i do not have time to analyze and rewrite, but just want to reuse somehow.

* PS - what if the subroutine would return an internal table which result should be the result of the OData service?

View Entire Topic
junwu
Active Contributor

it is called custom entity, google it.

rosenpetrov
Explorer
0 Kudos
Thank you, junwu, that is what i needed two weeks ago.