Skip to Content
author's profile photo
Former Member

Automatically Publish CDS View as OData Service

Hi guys,

in a HANA course I heard that you can publish a CDS view automatically as an OData service in the ABAP AS with the use of one single annotation.

Now I have been searching for said annotation for an hour and I can't find anything. It doesn't help that there is no SAP documentation for available annotations...

Do you know anything about that CDS annotation that converts your CDS view into an OData service automatically?

Regards,

Klaus Kronawetter

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

2 Answers

  • Best Answer
    Sep 30, 2015 at 01:02 PM

    @OData.publish: true

    Although you didn't find documentation on this because I don't believe this feature is released yet. This part of the ABAP innovations coming later this year to support S/4.

    Add comment
    10|10000 characters needed characters exceeded

    • Hello Thomas,

      I've got access to a ABAP AS 750 and the @OData.publish: true is working as expected and after the registration of service I've got to consume it on SAP Wed IDE for smart app template. Though no annotation file is available for selection.

      I understood it should be visible by calling

      /sap/opu/odata/IWFND/CATALOGSERVICE;v=2/Annotations(TechnicalName='XXXXX',Version='0001')/$value

      where XXX is the annotation model assigned to the odata service. Unfortunately on activation of CDS no model is assigned so that no annotation file reach WED IDE. The point is I'm missing something ?Is there a default annotation model to assign manually ?

      thank you for any help,

      V.Paderni

  • Sep 30, 2015 at 02:48 PM

    Hi Klaus,

    concerning "It doesn't help that there is no SAP documentation for available annotations...".

    That is not completely true although there is no central landing page to identify them all, but the ABAP keyword help on ABAP CDS views contains a description of the available annotations at the relevant keywords. Currently, that is for view definition and elements in a select list:

    As Thomas already stated the annotation your are looking for is not available in NW 7.40. It should come with NW 7.50 with a lot of other annotations that will make life easier (especially when thinking about UI integration). This is also the reason you should use the semantic annotations available at the moment although they are not really of use in the current NW release


    Best regards

    Christian


    Add comment
    10|10000 characters needed characters exceeded