Metadata Extension is useful in segregating the UI/Consumption related annotations from the Actual CDS.
It is very handy for enhancing the UI without impacting the CDS. It establishes a loose coupling between Data Model and UI annotations.
@Metadata.allowExtension: true
CDS access control is used to perform authorization checks.
Annotation used is @AccessControl.authorizationCheck
Annotation used is @AccessControl.authorizationCheck
If logic is more complex then CDS cannot help in achieving code pushdown. We will have to use Table function with CDS.
ABAP CDS is reusable.
CDS helps in achieving code pushdown.
Act as a single model for Fiori apps.
Can help us to write SQL script inside ABAP using Table function.
CDS helps in achieving code pushdown.
Act as a single model for Fiori apps.
Can help us to write SQL script inside ABAP using Table function.
CDS View activation generates 2 objects:
CDS View Entity(consumed everywhere) & SQL view at DDIC level.
Cardinality is used to define the relationship among tables. It can be such as ZERO TO ONE, ONE to ONE,ONE To MANY, MANY to ZERO represented as [0..1],[1..1], [1..*], [*..0]
Path expression is like a where condition which is used inside the CDS select to filter the data.
CDS View Entity(consumed everywhere) & SQL view at DDIC level.
Cardinality is used to define the relationship among tables. It can be such as ZERO TO ONE, ONE to ONE,ONE To MANY, MANY to ZERO represented as [0..1],[1..1], [1..*], [*..0]
Path expression is like a where condition which is used inside the CDS select to filter the data.
ABAP CDS & HANA CDS.
Further ABAP CDS has categories:
Interface Views,
Composite Views &
Consumption Views.
Now we have further types under these:
CDS with Parameter
CDS with join
CDS with association
Extend view etc.
Further ABAP CDS has categories:
Interface Views,
Composite Views &
Consumption Views.
Now we have further types under these:
CDS with Parameter
CDS with join
CDS with association
Extend view etc.
"@ObjectModel.foreignKey.association:’_AssicationName’: This Annotation is used for Value Help from association based on the Key Field.
@ObjectModel.text.element: [‘Fieldname’]: This annotation is used for Value Help for Key field to display the Text also. E.g field name is Customer Name for Customer Number.
@Consumption.valueHelp: This Annotation is used for Value Help from Associations.
@Consumption.valueHelpDefinition: This Annotation Used for Value Help from another CDS view or Value Help CDS."
@ObjectModel.text.element: [‘Fieldname’]: This annotation is used for Value Help for Key field to display the Text also. E.g field name is Customer Name for Customer Number.
@Consumption.valueHelp: This Annotation is used for Value Help from Associations.
@Consumption.valueHelpDefinition: This Annotation Used for Value Help from another CDS view or Value Help CDS."
Association is conceptually Adhoc join or Join on demand. It helps us to achieve better performance and better navigation. Very useful from Fiori apps perspective.
"Use of Order BY cluase while selecting data from tables.
Use of Inline declaration.
Use of Inner join on tables compared to For all entries. Use of data calculation related functions while selecting the data to reduce further roundtrip from DB.
All cluster and some pooled tables are converted to transparent tables in HANA. Hence queries on Cluster/pooled tables returns results sorted by primary keys is no more true here. Any custom coding which accesses physical table cluster/pool has to be changed so that the program reads from tables directly"
Use of Inline declaration.
Use of Inner join on tables compared to For all entries. Use of data calculation related functions while selecting the data to reduce further roundtrip from DB.
All cluster and some pooled tables are converted to transparent tables in HANA. Hence queries on Cluster/pooled tables returns results sorted by primary keys is no more true here. Any custom coding which accesses physical table cluster/pool has to be changed so that the program reads from tables directly"
There might not be any need of indexes and secondary indexes in S/4 HANA as the whole table fields act like the index. But standard sap tables are delivered with indexes and we can define and use secondary indexes as well.