In the SAP ecosystem, Core Data Services (CDS) have become the cornerstone of modern data modeling, especially within SAP HANA Live and SAP S/4HANA environments. CDS Views provide a powerful semantic layer directly on top of the database that allows developers to create reusable, flexible, and semantically rich data models. This article explores how CDS Views revolutionize data modeling in SAP HANA Live, their architecture, key features, and best practices for building effective models.
Core Data Services (CDS) is a framework that allows defining structured views on database tables or other CDS Views using a high-level, declarative SQL-based syntax enhanced with annotations. These views expose business-relevant entities such as sales orders, customers, or products in a semantically meaningful way.
CDS Views serve as a foundation for real-time operational reporting, analytical queries, and application development in SAP HANA Live environments without the need for data replication or separate data warehouses.
CDS Views allow developers to express business logic and relationships in the data model itself using annotations and associations, moving beyond physical tables to concepts relevant to business users.
CDS Views can be layered and combined, allowing the reuse of existing models to build complex, maintainable data structures.
CDS Views are tightly integrated with the ABAP stack and SAP HANA database, enabling:
CDS Views are optimized for SAP HANA’s in-memory computing, pushing down computations to the database layer, which ensures faster data retrieval and reduces application server load.
Associations define semantic relationships between entities, enabling navigation and lazy loading of related data without immediate joins.
Annotations enrich CDS Views with metadata about UI presentation, semantics, analytics, or security, enhancing integration with SAP tools.
Example annotations include:
@UI.lineItem for table columns in Fiori apps.@Analytics.dataCategory to specify the analytical context.CDS Views support parameters to enable dynamic data selection, allowing flexible filtering or input-driven queries.
@AbapCatalog.sqlViewName: 'ZSDORDER'
@AccessControl.authorizationCheck: #CHECK
@EndUserText.label: 'Sales Order Basic Data'
define view Z_CDS_SalesOrder as select from sales_order as so
association [0..1] to customer as _Customer on so.customer_id = _Customer.customer_id
{
key so.sales_order_id,
so.order_date,
so.status,
_Customer.customer_name
}
This simple CDS view models sales orders with a navigational link to customer data, embedding both data and semantic meaning.
SAP HANA Live initially provided pre-built HANA calculation views for operational reporting. However, the evolution toward SAP S/4HANA and modern SAP architectures has made CDS Views the preferred modeling technique. CDS provides:
Data modeling with CDS Views marks a paradigm shift in how SAP customers and developers create, manage, and consume enterprise data models. By abstracting database tables into semantically meaningful entities, enabling reusable, modular views, and supporting rich annotations and associations, CDS Views empower real-time analytics and application development in SAP HANA Live environments.
For any organization aiming to leverage the full power of SAP HANA and S/4HANA, mastering CDS Views is essential to building scalable, maintainable, and performance-optimized data models.