Ansicht
Dokumentation

ABENSAP_PUFFERING - SAP PUFFERING

ABENSAP_PUFFERING - SAP PUFFERING

TXBHW - Original Tax Base Amount in Local Currency   BAL_S_LOG - Application Log: Log header data  
This documentation is copyright by SAP AG.
SAP E-Book

- Table Buffering

Table buffering buffers data from the database in a table buffer in the shared memory of the current . Table buffering is possible for the following objects and takes place when they are accessed using :

For more information, see DDIC - Table Buffering of Database Tables.
For more information., see DDIC - Database Views.
For more information., see ABAP CDS - Table Buffering of CDS View Entities.
For more information., see ABAP CDS - Table Buffering of CDS DDIC-Based Views.

The definitions determine whether and how a DDIC database table, DDIC database view or CDS view entity is buffered. Using buffering generally improves performance (by factors of between 50 and 500), since the data does not need to be transported between the AS ABAP and the database server each time and because process changes can be prevented.

When a DDIC or CDS object, for which table buffering is defined, is accessed using , table buffering is active by default. Table buffering is performed by the database interface when buffered tables or views are accessed using statements. If a program uses to read data in a buffered table or view, the table or view is accessed using the table buffer, with some exceptions. To do this, the database interface determines whether this data is in the table buffer of the current . If this is the case, the data is read directly from the buffer. If the data is not contained in the buffer of the , the data is read from the database and loaded into the buffer. This means the data can accessed from the buffer next time. Writes cause asynchronous buffer synchronization.

The buffering type defines which records are loaded into the buffer when it is accessed. There are also, however, variants of statements that cannot be executed using the table buffer and which therefore bypass table buffering. Native SQL access or AMDP methods are applied to the database directly and therefore always bypass table buffering.

Notes

  • Typical candidates for buffering are customizing tables and system tables. In certain cases, customizing-like tables with master data can also be buffered. If it is vital that current data is accessed from a buffered table, the addition BYPASSING BUFFER of the statement SELECT can be used. If this addition is used a lot, the table should be checked for its suitability for buffering or whether the current data is really always required.
  • Buffering is not recommended for tables in the following cases:

  • Many writes are performed on the tables. If more than one percent of the accesses are writes, buffering should be avoided, so that the extra work caused by synchronization does not outweigh the benefits of buffering.

  • Null values are handled as null values in the table buffer. They are not transformed to type-dependent initial values.
  • Tables or views that can also be accessed using Native SQL or AMDP should not be buffered. If Native SQL statements or AMDP methods modify data in buffered tables or views, this is ignored by the database interface and the buffers are not synchronized accordingly. This can cause inconsistencies between the data in the buffers and on the database.
  • A self-defined buffering of formatted data in the shared memory is possible using shared objects.
  • Except in the case of database access, table buffering also applies to database access from classic dynpros.





PERFORM Short Reference   Addresses (Business Address Services)  
This documentation is copyright by SAP AG.

Length: 8252 Date: 20240424 Time: 020037     sap01-206 ( 96 ms )