ERPClimb logoERPClimb
CDS Views
Architect / Cross-trackintermediate 8 min read

CDS Views Part 5: VDM Layering — Basic, Composite and Consumption Views

Preview · a free account unlocks the full lesson

Key takeaway

Understand the Virtual Data Model (VDM) layers used in S/4HANA: basic interface views over single tables, composite views that combine them, and consumption views built for one app or report. Learn naming, the @VDM annotations and how to reuse SAP's released I views.

In this lessonShow sections

Visual overview

CDS Views Part 5: VDM Layering — Basic, Composite and Consumption Views — learning sheetFlow: Search SAP's views in ADT (Ctrl+Shift+A, "I_Customer"), check the API state → Build ZI_Customer (basic) over KNA1 → Build ZI_SalesOrderComp (composite) over VBAK with an association to ZI_Customer → Build ZC_SalesOrderOverview (consumption) exposing only the fields one report needs. Key ideas: BASIC (INTERFACE) VIEWS; COMPOSITE VIEWS; CONSUMPTION VIEWS; RELEASED VIEWS AND STABILITY. Watch out: Build on SAP's released I_ views where possible (C1 release contract) — they stay stable across upgrades; direct table access and unreleased views may break.ERPClimb.com / ARCH / LESSON 5/10 / LEARNING SHEETCDS Views Part 5: VDM Layering — Basic, Composite andConsumption Views1 · HOW IT FLOWS1Search SAP'sviews in ADT(Ctrl+Shift+A…2BuildZI_Customer(basic) over…3BuildZI_SalesOrderComp(composite) over…4BuildZC_SalesOrderOverview(consumption)…2 · KEY IDEAS EXPLAINEDBasic (Interface) ViewsOne main data source (usually one table), no heavylogic.Business aliases, key definition, currency/unitreferences, associations to related basic views.Composite ViewsCombine basic views via associations or joins; mayadd calculations and aggregations.Still reusable — not tied to one app.Consumption ViewsBuilt for one purpose: a Fiori app, an ODataservice, an analytical query or a report.Contain UI, search and analytical annotations(Part 7), selection of only needed fields,sometimes parameters.Released Views And StabilitySAP marks some views as released (API state"Released" in ADT, C1 contract for usein key user / cloud development).In S/4HANA Cloud and ABAP Cloud, only releasedobjects may be used.3 · REMEMBER · WATCH OUTRememberVDM = Virtual Data Model: S/4HANA's layered CDS architecture — basic(I_), composite (I_) and consumption (C_) views.Basic views sit on one table, give business names and stay free of applogic; composite views combine basic views; consumption views are…@VDM.viewType: #BASIC / #COMPOSITE / #CONSUMPTION documents the layer.!Watch outBuild on SAP's released I_ viewswhere possible (C1 release contract)— they stay stable across upgrades;direct table access and unreleasedviews may break.4 · IN A REAL PROJECTOn a global S/4 rollout, each market team wrote its own sales views directly on VBAK/VBAP/KNA1. After twoyears there were 60 overlapping views, and a change in how "open value" was calculated had to beapplied in 14 places. The architecture team introduced a VDM rule: ZI_ basic views per business object, shared…Original ERPClimb learning sheet • Verify against your SAP release and edition

Explanation

Parts 1 through 4 built single views; real projects instead need an architecture of views that can be reused and maintained, which is what the Virtual Data Model (VDM) provides — S/4HANA's layered CDS architecture made up of basic views, composite views, and consumption views.

Basic (interface) views sit on one main data source, usually a single table, and carry no heavy application logic. They give business names to fields, define keys, reference currencies and units, and provide associations to related basic views — SAP's own I_Customer, I_SalesOrder, and I_Product are examples, and the customer naming convention is ZI_<BusinessObject>.

Composite views combine basic views, typically via associations or joins, and may add calculations and aggregations; they're still reusable and not tied to any one app — a sales order view enriched with customer name and open value is a typical example.

Consumption views, by contrast, are built for one specific purpose — a Fiori app, an OData service, an analytical query, or a report.

They contain UI, search, and analytical annotations (covered in Part 7), select only the fields that purpose needs, and sometimes take parameters; the naming convention is ZC_<Purpose>, and consumers should generally only read consumption views or released interface views. The @VDM.viewType: #BASIC / #COMPOSITE / #CONSUMPTION annotation documents which layer a given view belongs to.

Free account

Create a free account to keep reading

You have read the opening of this lesson. A free ERPClimb account unlocks the rest of it, every other lesson and topic, and your learning history, so you can pick up exactly where you stopped. No card needed.

  • Full explanation
  • Code example
  • Real project scenario
  • Common mistakes
  • Best practices
  • Interview angle

One tap with Google works too. Every topic keeps its first lesson open to everyone.

Keep exploring

Referenced SAP objects

Reviewed reference pages for the objects this page mentions.

Check before use: lesson examples are educational, not a guarantee of correctness for your SAP edition or release. Sample code has not been executed on your SAP system. Confirm API availability, syntax, authorizations and business impact in an approved development or test environment.