Get Example source ABAP code based on a different SAP table
Overview of ABAP-Managed Database Objects ABAP-managed database objects> can be the following:
An instance of a transparent table> defined in the ABAP Dictionary.
The name of the database table on the database matches the name of the table in the ABAP Dictionary.
The key fields defined in the ABAP Dictionary are the primary key of the database table on the database.
The indexes defined in the ABAP Dictionary are created on the database.
The order of the fields in the ABAP Dictionary does not need to match the order and on the database.
An instance of a DDIC database view> defined in the ABAP Dictionary.
The database object of a DDIC database view is implemented as an SQL view> using a platform-dependent database statement CREATE VIEW>, which is itself based on the definition of the DDIC database view in the ABAP Dictionary.
The name of the view on the database matches the name of the table in the ABAP Dictionary.
The key fields of a DDIC database view defined in the ABAP Dictionary are ignored on the database.
Instance of a CDS view> defined in ABAP CDS.
In CDS views that are not defined with the addition ENTITY>> of the statement DEFINE VIEW>>, an additional ABAP_CDS_MNG_VIEW > is created in the ABAP Dictionary whose name is specified in the definition of the CDS view with the annotation @AbapCatalog.sqlViewName >. The same applies as to DDIC database views, where instances of CDS views with input parameters can also be created as database functions using CREATE FUNCTION>, depending on the database platform, as is currently the case on SAP HANA databases.
In CDS views defined using the statement DEFINE VIEW ENTITY>>, an identically named SQL view> or a database function on the database is created directly from the definition of the CDS entity.
Instances of AMDP procedures> and AMDP functions>
The AMDP framework copies the source code of AMDP procedure implementations> and AMDP function implementations > from AMDP classes> to a database procedure> managed by the framework.
The name of an AMDP-managed database procedure is CLASS=>METH>, where CLASS> is the AMDP class> and METH> is the AMDP method>.
The parameter interface of an AMDP-managed database procedure is generated as a platform-dependent interface from the parameter interface of the AMDP method>.
Instance of the AMDP functions> of CDS scalar functions>
CDS scalar functions are implemented in AMDP function implementations> whose parameter interface is defined by the CDS scalar function.
The same applies as to general AMDP methods >.
Instance of the AMDP functions> of CDS table functions>
CDS table functions are implemented in AMDP function implementations> whose parameter interface is defined by the CDS table function.
The same applies as to general AMDP methods >.
Instance of a CDS hierarchy>
Instances of CDS hierarchies are created as special views on the database, which access a built-in hierarchy function on the database.
The name of the view on the database matches the name of the CDS hierarchy.
Instances of ABAP-specific session variables
The SAP HANA database has special ABAP-specific session variables> whose content matches the value of specific ABAP system fields> when accessed from ABAP. Some of these variables can also be modified from ABAP.
On other database platforms, these ABAP-specific session variables exist only when CDS views> are accessed using AB_SQL >.
Instances of dependency rules> defined in ABAP Dictionary on the SAP HANA database. In addition to the database objects themselves, their definitions in the AS ABAP framework cover further properties described using metadata that are not known to the database. The most important of these properties are:
Use as data types
The database tables and DDIC database views in the ABAP Dictionary can be used in the ABAP Dictionary itself and as structured types> in ABAP programs.
CDS entities> can be used as structured types>. In the ABAP Dictionary, the data types of the components of the database tables and views are based on built-in dictionary types>. These types are an ABAP-specific wrapper of the actual database types and have ABAP-specific properties.
Client dependency
Database tables and DDIC database views whose first column is a client column> with the built-in dictionary type CLNT>> are client-dependent>.
The annotation @ClientHandling.typ>> or the obsolete annotation @ClientDependent>> define whether CDS views> and CDS table functions> are client-dependent.
Table buffering
In ABAP Dictionary, it is possible to define whether and how table buffering> takes place for database tables and DDIC database views.
Table buffering of CDS views> is defined by the annotation @AbapCatalog.buffering> >.
Enhancements
An enhancement category of DDIC structures> can be defined in the ABAP Dictionary for database tables.
The enhancement of CDS views> is defined by the annotation @AbapCatalog.viewEnhancementCategory>.
For ABAP_CDS_V2_VIEWS > and CDS projection views>, special extensibility annotations @AbapCatalog.extensibility>> are available.
Foreign key dependencies
In the ABAP Dictionary, foreign key dependencies> between foreign key tables> and check tables> can be defined for database tables. Text tables> are special foreign key tables that link the lines in check tables with language-specific texts.
Logging
Logging> can be enabled in the ABAP Dictionary for database tables.
Access control
CDS roles> from CDS access control> can be defined for CDS views> and CDS table functions> and configured using the annotation @AccessControl.authorizationCheck>.
Reference fields
For table fields or view fields with the built-in data types> CURR> and QUAN>, reference fields of the types CUKY> and UNIT> must be defined in the ABAP Dictionary.
For the elements of CDS views> and CDS table functions>, the relationships to reference fields are defined using @Semantics annotations>>.
Translatable texts
For database tables and DDIC database views, translatable short texts and documentation can be created in the ABAP Dictionary.
For CDS views> and CDS table functions> and their elements, translatable texts are defined using @EndUserText>> annotations.
AMDP classes> and AMDP methods> are documented in the same way as regular classes> in ABAP Doc> or in classic class documentation. In AS ABAP, the database objects managed by the ABAP Dictionary, ABAP CDS, and AMDP are represented by repository objects> that have a package> interface to the Change and Transport System (CTS)>. The actual database objects are created and modified using internal DDL statements and the AS ABAP database interface>. The ABAP Dictionary, ABAP CDS, and AMDP frameworks, together with the Change and Transport System (CTS)>, ensure that complete and consistent ABAP-managed database objects are available to be accessed from AS ABAP.
Latest notes: The overview above does not contain any database objects created by AS ABAP on the database for purely technical reasons and which should therefore never be accessed. Examples are database objects in the AMDP framework that are part of the framework itself, unlike AMDP procedures and AMDP functions. ABAP_HINT_END