layout | shorty | synopsis | status | uacp |
---|---|---|---|---|
cds-ref |
Annotations |
Find here a reference and glossary of common annotations intrinsically supported by the CDS compiler and runtimes.
|
released |
Used as link target from Help Portal at https://help.sap.com/products/BTP/65de2977205c403bbc107264b8eccf4b/855e00bd559742a3b8276fbed4af1008.html |
{{ $frontmatter.synopsis }}
Learn more about the syntax of annotations.{.learn-more}
Annotation | Description | Alternatives |
---|---|---|
@title |
Common.Label |
|
@description |
Core.Description |
Annotation | Description |
---|---|
@readonly |
see Input Validation |
@insertonly |
see Generic Handlers |
@restrict |
see Authorization |
@requires |
see Authorization |
Annotation | Description |
---|---|
@readonly |
see Input Validation |
@mandatory |
see Input Validation |
@assert.unique |
see Input Validation |
@assert.integrity |
see Input Validation |
@assert.target |
see Input Validation |
@assert.format |
see Input Validation |
@assert.range |
see Input Validation |
@assert.notNull |
see Input Validation |
Annotation | Description |
---|---|
@path |
see Services |
@impl |
see Reuse & Compose |
@odata.etag |
see Providing Services |
@cds.autoexpose |
see Providing Services |
@cds.api.ignore |
see OData |
@cds.query.limit |
see Providing Services |
@cds.localized |
see Localized Data |
@cds.valid.from/to |
see Temporal Data |
@cds.search |
see Search Capabilities |
Annotation | Description |
---|---|
@cds.persistence.exists |
tells compile.to.sql this is created otherwise |
@cds.persistence.table |
tells compile.to.sql to create a table, not a view |
@cds.persistence.skip |
tells the compiler, this entity shall not exist in database at all |
@cds.persistence.mock |
false excludes this entity from automatic mocking |
@cds.on.insert |
see Providing Services |
@cds.on.update |
see Providing Services |
Learn more about OData Annotations in CDS.{.learn-more}
Shortcuts:
Annotation | Description |
---|---|
@ValueList.entity |
see Domain Modeling |
@odata.Type |
see OData |
@odata.MaxLength |
see OData |
@odata.Precision |
see OData |
@odata.Scale |
see OData |
@odata.singleton |
see OData |
Intrinsically supported OData Annotations:
Annotation | Description |
---|---|
@Core.Computed |
see Providing Services |
@Core.Immutable |
see Providing Services |
@Core.MediaType |
see Media Data |
@Core.IsMediaType |
see Media Data |
@Core.IsUrl |
see Media Data |
@Capabilities... |
see Fiori |
@Common.FieldControl |
see Input Validation) |