Skip to content

Replace 'entity' identifier example from cdl.md #1982

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 5 additions & 9 deletions cds/cdl.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,23 +41,19 @@ The *Conceptual Definition Language (CDL)* is a human-readable language for defi

```cds
namespace capire.bookshop;
using { managed } from `@sap/cds/common`;
aspect entity : managed { key ID: Integer }
using { managed, cuid } from `@sap/cds/common`;
aspect primary : managed, cuid {}

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

entity Authors : entity {
entity Authors : primary {
name : String;
}
```

::: details Noteworthy...
In the example above `entity` shows up as a keyword, as well as an identifier of an aspect declaration and references to that.
:::

Keywords are *case-insensitive*, but are most commonly used in lowercase notation.

Identifiers are *case-significant*, that is, `Foo` and `foo` would identify different things.
Expand All @@ -69,7 +65,7 @@ type ![Delimited Identifier] : String;
```

::: warning Avoid using delimited identifiers
Delimited identifiers in general, but in particular non-ASCII characters, or keywords as identifiers should be avoided as much as possible, for reasons of interoperability.
Delimited identifiers in general, but in particular non-ASCII characters, should be avoided as much as possible, for reasons of interoperability.
:::


Expand Down