SAP ABAP Data Element OIC_CALCTYP (Calculation type for formula condition item)
Hierarchy
BBPCRM (Software Component) BBPCRM
   CRM (Application Component) Customer Relationship Management
     CRM_APPLICATION (Package) All CRM Components Without Special Structure Packages
       OIC (Package) MAP Marketing, Accounting and Pricing
Basic Data
Data Element OIC_CALCTYP
Short Description Calculation type for formula condition item  
Data Type
Category of Dictionary Type D   Domain
Type of Object Referenced     No Information
Domain / Name of Reference Type OIC_CALCTYP    
Data Type CHAR   Character String 
Length 1    
Decimal Places 0    
Output Length 1    
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 Calc.type 
Medium 15 Item calc.type 
Long 20 Item calculat. type 
Heading CalTy 
Documentation

Definition

This field controls, how the calculation is performed within a term item line.

The calculation mode 'rate based calculation' (new since release 4.6B) needs the option to define different references within a term item line. These references are controlled by the calculation type. The selected calculation type influences the intermediate results of the calculation and also the formula result.
(More details see below)

For the two possible calculation modes within the Formula and Average module, 'value based' and 'rate based', it is described below, how the calculation type effects the evaluation within a term item line.

Procedure

Value based calculation mode

    Leave the calculation type initial (<SPACE>)

Rate based calculation mode

    Choose one of the values for the calculation type: 1, 2 or 3.

Allowed values for the different calculation modes

Value based calculation of the formula (Indicator for rate based calculation is switched off)

  • Allowed value for CALCTYP:     <SPACE>

    Value based calculation was the only possible calculation mode before release 4.6B. To ensure upgrade compatibility from older releases to release 4.6B the calculation type field must be initial ( <SPACE> ). Therefore no data adaption is needed, when F&A formulas are upgraded to release 4.6B. Selecting other values leads to an error message.

Rate based calculation of the formula (Indicator for rate based calculation is switched on)

  • Allowed values for CALCTYP:     1, 2 or 3
  • The values 4, 5 and 6 are not supported in the moment. They are foreseen for future purposes. Selecting them leads to an error message.
  • The value <SPACE> is only allowed for value based calculation and leads also to an error message.

Evaluation steps for value based calculation
(like before release 4.6B)

For value based calculation mode the intermediate results of the evaluation are values, defined in a currency .
To combine these values in aritmetic expressions, it has to be ensured that the concerned rates are in the same currency. This is ensured by using a calculation currency (which is the rate currency, if filled, otherwise the document currency). This calculation currency is valid for the whole formula. Therefore on item level there is no need to have different calculation types. This is reflected by only one allowed value for the calculation type (<SPACE>).
The processing steps for value based calculation are always:

  1. Daily quotation prices are multiplied with the corresponding quantity to calculated the daily quotation value. This value is then converted to the calculation currency.
  2. The daily quotation values are summed up and the average quotation value is calculated.
  3. The average quotation value can be rounded using the rounding function.
  4. The surcharge is multiplied with the corresponding quantity to calculate the surcharge value. This value is then converted to the calculation currency.
  5. If daily currency conversion is selected in the currency rules the previous step is done on daily level. Therefore an average surcharge value is calculated.
  6. The (average) surcharge value can be rounded using the rounding function.
  7. The rounded average quotation value and the rounded (average) surcharge value (both in calculation currency) are combined depending on the calculation exit for the term item. The result is the item value, expressed in n [currency] (e.g. 1000 USD).
  8. The item value can be rounded using the rounding function.
  9. The rounded item values within a term are added to the term value.
  10. The term value can be rounded using the rounding function.
  11. Applying the AvB rule determines a intermediate value, which is converted to the document currency and is the formula value. This value is transferred back to the pricing module and can be seen on the pricing screen.

Evaluation steps for rate based calculation
(since release 4.6B)

For rate based calculation mode the intermediate results of the evaluation are rates, defined in a combination of a currency key, a pricing unit and a unit of of measure (Cuky/Prun/UoM). To combine these rates in aritmetic expressions, it has to be ensured that the concerned rates are in the same Cuky/Prun/UoM combination.
The calculation type controls, which are the reference Cuky/Prun/UoM combinations for the different evaluation steps.

  1. The daily quotations are defined in the combination Cuky_dQ / Prun_dQ / UoM_dQ.
  2. The daily quotations are converted to the reference combination Cuky_1 / Prun_1 / UoM_1, which is defined by the calculation type:
    1. Calculation type = 1

      The reference is the combination of the formula:
      Cuky_F / Prun_F / UoM_F.

      Cuky_F = Rate currency (RATECURR), if not initial, otherwise
      formula currency (FORMCURR).

      Prun_F = Formula pricing unit (FORMPER), if not initial,
      otherwise '1'.

      UoM_F = Formula UoM (FORMUOM), if not initial, otherwise the
      UoM from the pricing/condition screen (KOMP-VRKME;
      sales UoM in SD, price UoM in MM).
    2. Calculation type = 2 and 3

      The reference is the combination of the used quotation Cuky_Q / Prun_Q / UoM_Q (from the quotation check table).
      Note: If gross/net substitution is active for this quotation, the unit of measures UoM_dQ and UoM_Q might be different. Therefore a conversion is performed.
  3. The converted daily quotation prices (rates) are summed up and the average quotation price is calculated.
  4. The average quotation price can be rounded using the rounding function.
  5. The rounded average quotation price is converted to another reference combination Cuky_2 / Prun_2 / UoM_2, which is defined by the calculation type:
    1. Calculation type = 1

      The reference is the combination of the formula Cuky_F / Prun_F / UoM_F.
      Because this is the same reference like in step 2, no conversion is performed.
    2. Calculation type = 2

      The reference is the combination of the used quotation Cuky_Q / Prun_Q / UoM_Q (from the quotation check table).
      Because this is the same reference like in step 2, no conversion is performed.
    3. Calculation type = 3

      The reference is the combination of the used surcharge Cuky_S / Prun_S / UoM_S (before potential gross/net substitution).
      A conversion is performed, if this combination differs from the one of step 2.
  6. The specified surcharge (rate) is converted to the reference combination Cuky_2 / Prun_2 / UoM_2, which is the same like in step 5. The calculation type defines the processing:
    1. Calculation type = 1

      The reference is the combination of the formula Cuky_F / Prun_F / UoM_F.
      A conversion is performed, if the combinations Cuky_S / Prun_S / UoM_S and Cuky_F / Prun_F / UoM_F differ.
    2. Calculation type = 2

      The reference is the combination of the used quotation Cuky_Q / Prun_Q / UoM_Q (from the quotation check table).
      A conversion is performed, if the combinations Cuky_S / Prun_S / UoM_S and Cuky_Q / Prun_Q / UoM_Q differ.
    3. Calculation type = 3

      The reference is the combination of the used surcharge Cuky_S / Prun_S / UoM_S (before potential gross/net substitution).
      No conversion is performed.
  7. If daily currency conversion is selected in the currency rules the previous step is done on daily level. Therefore the daily surcharges are summed up and an average surcharge (rate) is calculated.
  8. The average surcharge can be rounded using the rounding function.
  9. The rounded average quotation price and the rounded (average) surcharge rate (both in the combination Cuky_2 / Prun_2 / UoM_2) are combined depending on the calculation exit for the term item. The result is the item rate in Cuky_2 / Prun_2 / UoM_2 (e.g. 1000 ITL / (10 L15) ).
    Note: Cuky_2 / Prun_2 / UoM_2 can be different for each term item line.
  10. The item rate is converted to the combination Cuky_F / Prun_F / UoM_F to ensure that the item rates within a term can be added.
  11. The item rate in the combination Cuky_F / Prun_F / UoM_F can be rounded using the rounding function.
  12. The term rates are calculated by adding the rounded item rates. The term rates are also calculated in Cuky_F / Prun_F / UoM_F.
  13. Applying the AvB rule determines a formula rate specified in Cuky_F / Prun_F / UoM_F.
    (This rate is transferred back to the pricing module and displayed on the pricing screen as the rate of the F&A condition type).
  14. The quantity of
History
Last changed by/on SAP  20050224 
SAP Release Created in