3 Ways to Find SAP ABAP CDS Views Examples and Demos from SAP

CDS Views

SAP demos and examples are a great orientation for how SAP is doing things. But it is not as easy as one thinks to find meaningful SAP ABAP CDS view demos or examples in an ECC or S/4 HANA system.

These are 3 ways to find SAP ABAP CDS views implemented by SAP to orient towards them.

1. SAP ABAP CDS Views Demo Package in ECC and S/4 HANA System

There is a SAP ABAP CDS views demo package full of demo files. It is called SABAPDEMOS and you can find it either in the transaction SE80 or in Eclipse. It is available in every system with at least ABAP 7.40 SP05.

Depending on your ABAP version there might be more or less demo files in the SABAPDEMOS package because SAP continuously added new files to this package. Almost whenever the ABAP stack was updated and new features were released for ABAP CDS views then the package grew.

In Eclipse open the ABAP Development Object Dialog by pressing CTRL + SHIFT + A or through the menu: Navigate > Open ABAP Development Object. Once the dialog is open enter in the search field SAPABAPDEMOS. Now you should see the SABAPDEMOS package.

But be careful about the naming conventions of these files. Actually, they do not meet the naming conventions of SAP for CDS views like starting basic and composite views with an I_, and consumption view with a C_. Who knows why.

However, depending on your ABAP version you might find those files:

  • ABAP CDS views with different types of joins, union, and associations
  • ABAP CDS view with currency and unit conversion
  • ABAP CDS views with parameters
  • ABAP CDS views with SQL functions
  • ABAP CDS views with different annotations
  • ABAP CDS views with extensions
  • ABAP CDS views with table functions
  • ABAP CDS views with authorization checks
  • Table functions
  • Access Controls (Authorization checks)

2. Fiori Standard Application OData Services in S/4 HANA System

In an S/4 HANA system are pre-installed SAP Fiori standard applications and their OData services. CDS views generate those OData services. Therefore, these CDS views exist somewhere in the S/4 HANA system.

Here is how you find them:

  1. Go to the SAP Fiori Apps Library.
  2. Navigate in the left menu: All apps for SAP S/4HANA > All apps for SAP S/4HANA.
  3. Select one of the applications in the list on the left – for example, the application Cash Flow Analyzer.
  4. On the detail view of the application, select IMPLEMENTATION INFORMATIONS in the tab bar.
  5. Expand the Configuration item.
  6. Get the name of the OData service under OData Service(s). For example, the OData service of the application Change Process Analysis for Business Partner is called MDC_PROC_BP_ALP_SRV.
  7. Copy the name of the OData service without the _SRV at the end. For example, from MDC_PROC_BP_ALP_SRV copy just MDC_PROC_BP_ALP.
  8. Go to the transaction SEGW in your S/4 HANA system.
  9. Click on Open Project.
  10. Paste the OData service name without the _SRV of the Fiori standard application.
  11. Select the project and open it.
  12. Open the project in the SEGW navigator on the left.
  13. Open in the project the folders Data Model > Data Source References > CDS-Entity Exposures > Entity Types.
  14. Here you see the names of the ABAP CDS views associated with this OData service. For example, an entity of the OData service MDC_PROC_BP_ALP of the application Change Process Analysis for Business Partner is C_MDBusPartChangeProcessType.
  15. Copy an entity, and therefore ABAP CDS view name and go to Eclipse.
  16. Press CTRL + SHIFT + A or go to Navigate > Open ABAP Development Object… in the top menu of Eclipse.
  17. Paste the ABAP CDS view name into the input field of the Open ABAP Development Object dialog. For example, C_MDBusPartChangeProcessType.
  18. Open the CDS view.

3. Eclipse ABAP Development Object Type Search

In Eclipse it is possible to search for specific ABAP object types. Therefore, it is possible to search just for CDS Views.

  1. Open Eclipse.
  2. Press CTRL + SHIFT + A or navigate in the top menu to Navigate > Open ABAP Development Object…
  3. Enter in the Open ABAP Development Object input field any string and type:ddls. For example, I* type:ddls. Use type:dcls for access controls.
  4. Now you see all ABAP CDS views which names are starting with an I in the result list. The * is a wild card in the search.
  5. Go through the result list and open an ABAP CDS views which sounds interesting.
  6. Tip: SAP does not continuously stick to it, but the naming conventions for ABAP CDS views are that BASIC and COMPOSITE views start with an I_ and that CONSUMPTION views start with a C_. Therefore, a search for I_* type:ddls results in a search for basic and composite views and a search for C_* type:ddls results in a search for consumption views.
1 Comment
Get Dose for Excel
Dose for Excel screenshot.

Dose for Excel adds 100+ advanced functions and features for Microsoft Excel.

For example, you can:

  • Export sheets quickly
  • Merge cells or rows or columns without losing data
  • Comments assistant
  • Count cells by color
  • Advanced built-in formulas
  • Advanced built-in functions
  • Auto backup your workbooks easily
  • Lots more

Check it out here!

Get A COMPLETE SAP Modules Overview infographic (free)

Plus, receive for free SAP tips & insights and all future infographics that are only shared with the private newsletter subscribers. 

Complete SAP modules/components overview infographic.
Latest Poll
Essential Ressources

1 Comment. Leave new

I want to find Number of Working days in CDS View can you please suggest me how we can achieve this requirement .


Leave a Reply

Your email address will not be published. Required fields are marked *

Fill out this field
Fill out this field
Please enter a valid email address.