Ansicht
Dokumentation

ABENCDS_CLIENT_HANDLING_ABEXA - CDS CLIENT HANDLING ABEXA

ABENCDS_CLIENT_HANDLING_ABEXA - CDS CLIENT HANDLING ABEXA

PERFORM Short Reference   General Material Data  
This documentation is copyright by SAP AG.
SAP E-Book

CDS Views, Client Handling

This example demonstrates how client-specific are handled.

Source Code

Execute

Description

The program accesses the following CDS views:

The view DEMO_CDS_SPFLI_CLIENT_0 is a regular client-specific in which the client column is not specified in the SELECT list. The DEMO_CDS_SPFLI_CLIENT_1 is used to demonstrate the behavior in rare cases where the client column is specified in the SELECT list of a client-specific CDS view.

RTTI is used to read the components of the associated data types:

  • The structure of the client-specific CDS entity without client column in the SELECT list does not have a client column.
  • The CDS managed DDIC view of the client-specific without client column in the SELECT list has a client column.
  • Nevertheless, the structure of the client-specific CDS entity with client column in the SELECT list does not have a client column.
  • The CDS managed DDIC view of the client-specific with client column in the SELECT list has a client column.

The statement SELECT is used to make the following accesses:

  • Regular access to a client-specific CDS entity without client column in the SELECT list. The data from the current client is read. The result set does not have a client column.
  • Regular access to a CDS managed DDIC view w of the client-specific CDS entity without client column in the SELECT list. The data from the current client is read. The result set has a client column.
  • Access to a client-specific CDS entity without client column in the SELECT list using the obsolete addition CLIENT SPECIFIED. The data of the client specified in the WHERE condition is read. A name myclient must be defined for this. The result set has a client column with this name.
  • Regular access to a CDS managed DDIC view of the client-specific CDS entity with client column in the SELECT list. The data from the current client is read. The result set does not have a client column.

The similar program DEMO_CDS_CLIENT_HANDLING_SV accesses CDS views in which the annotation @ClientHandling.algorithm: #SESSION_VARIABLE is used instead of @ClientHandling.algorithm: #AUTOMATED. The results are shown in exactly the same way as here, however access using the obsolete addition CLIENT SPECIFIED is not possible since the session variable $session.client is evaluated implicitly in the views.

Note

The accesses to the CDS managed DDIC views of shown here are for demonstration purposes only. This way of accessing is obsolete and only the CDS entities should now be accessed.






rdisp/max_wprun_time - Maximum work process run time   Fill RESBD Structure from EBP Component Structure  
This documentation is copyright by SAP AG.

Length: 4575 Date: 20240424 Time: 061015     sap01-206 ( 40 ms )