Defining Data Entities: What is CDS?

CAP CDS (Cloud Application Programming Model Core Data Services) is a key part of the SAP CAP (Cloud Application Programming Model) framework. Think of it as a simple, smart way to describe your data (like customers, orders, or products) in a format that is easy to understand and reuse across different apps. Instead of writing complex code for each service, CDS lets you define your data once, and then use it everywhere. This makes building apps faster and keeps everything consistent.

Integration with:

Example: Defining Entities with CDS

entity Authors {
    name  : String;
    books : Association to many Books;
}

entity Books {
    title  : String;
    author : Association to Authors;
    genre  : Association to Genres;
}

entity Genres {
    name   : String;
    parent : Association to Genres;
}

What this example defines: