SAP ABAP Data Element ODQ_ENTITYCNTR (Number of Data Units (Data Records for Example))
Hierarchy
SAP_BASIS (Software Component) SAP Basis Component
   BC-BW-SRV (Application Component) BW Generation Tool and Set Object
     SODQS (Package) Operational Delta Queue Services
Basic Data
Data Element ODQ_ENTITYCNTR
Short Description Number of Data Units (Data Records for Example)  
Data Type
Category of Dictionary Type D   Domain
Type of Object Referenced     No Information
Domain / Name of Reference Type ODQ_ENTITYCNTR    
Data Type DEC   Counter or amount field with comma and sign 
Length 19    
Decimal Places 0    
Output Length 26    
Value Table      
Further Characteristics
Search Help: Name    
Search Help: Parameters    
Parameter ID   
Default Component name    
Change document    
No Input History    
Basic direction is set to LTR    
No BIDI Filtering    
Field Label
  Length  Field Label  
Short 10 No. Units 
Medium 19 No. of Data Units 
Long 25 Number of Data Units 
Heading 25 Number of Data Units 
Documentation

Definition

The instance counter is a special key figure that can be totaled. It can be used in a delta process to synchronize a target table with an original table. The counter can also be used to count data records in a table. The instance counter can be interpreted as absolute or differential. In the case of absolute use, the value of the key figure must always be greater than or equal to 0. In the case of differential use, the value can be positive or negative. To differentiate between absolute and differential use in this document, we have devised the following approach: for absolute use, the value is never written with a +/- minus sign and for differential use, the value always has a +/- minus sign (even if the value is positive).

In the original table or source table, every valid data record implicitly has the value 1 (provided that the key is correctly defined). Data records that are to be declared invalid or logically deleted can adopt the value 0.

In any aggregate generated only from valid data records from a table of this type, the instant counter total can only adopt values that are greater or equal to 0. The total is only 0 if no valid data records are included in the aggregate.

If a delta transfer is performed, the instance counter can be interpreted absolutely or differentially, depending on the delta procedure being used.

Creating a Data Record

When a data record is created in the original table (Change Mode 'C'), the instance counter is increased by +1 (from 0 to 1). For this operation, the value is

  • always 1 for absolute interpretation (for example, overwriting delta).
  • always +1 for differential interpretation (for example, additive delta).

Changing a Data Record

When a data record is changed in the original table (Change Mode 'U'), the instance counter is not changed. There are three possibilities for delta:

  • With absolute interpretation, the source sends
    • only one delta data record with the value 1.

      This data record describes the after image (status of the data record after the change).

  • With absolute interpretation, the source sends
    • two delta data records with the values -1 and +1 or
    • only one delta data record with the value 0.

      The data record with the value -1 describes the before image (status of the data record before the change) and the data record with +1 describes the after image.

Deleting a Data Record

When a data record is deleted from the original table (Change Mode 'D'), the instance counter is decreased by -1 (from 1 to 0).

  • In the case of absolute interpretation, the value is always 0. The source in the delta data record only needs to provide the values of the key fields of the deleted original record.
  • In the case of differential interpretation, the value is always -1. The delta data record describes the before image (status of data record before it was deleted).

Classification of Delta Procedures

These definitions enable you to classify the delta information provided by a source, based on the combination of change mode and instance counter used:

  • No purely absolute delta procedure exists where the target table (which is synchronized with the original table using delta data records) is required to have a key equivalent to the original table.

Combinations    Description

[C1] U1    Only new and changed records but no deletions;
    C1 is optional and can be omitted in favor of U1,
    if no distinction can be made between new and modified records
    .

[C1] U1 D0    new, changed and deleted records;
    Again, C1 can be omitted in favor of U1,
    if no distinction can be made between new and changed records
    .

  • Purely differential delta procedures exist, where it must be possible to aggregate all non key fields and the aggregation operation must support an inverse element (as is the case when totaling values with inverse signs, for example). In this case, the source table and target table do not need to have an equivalent key.

Combinations    Description

[C+1] U0 [D-1]    Purely additive delta;
    In this case, the before image and after image are merged into one data record and the delta information can no longer be interpreted as absolute data.

  • In addition, mixed delta procedures also exist where a choice must be made for the target table; whether the delta data records should be interpreted absolutely (for example, overwrite) or differentially (for example, additive):

Combinations    Description

C+1    Only new records. No changes and no deletions

[C+1] U-1 U+1 [D-1]    Complete information on all changes to the original table; C+1 and D-1 are optional and can be

replaced by U+1 or U-1 if necessary.

Use

Dependencies

Example

History
Last changed by/on SAP  20130604 
SAP Release Created in 702