Saturday 9 April 2016

SAP SD Pricing VOFM Routines



Transaction VOFM is a tool that was developed in R/3 to facilitate the definition of both SAP delivered as well as customer defined routines/rules used in the system during various business processes. VOFM routines are ABAP code written in Forms. 

VOFM provides the user with the benefit of choosing from one of the standard delivered R/3 routines or writing their own. VOFM is intended for the implementation team when configuring the system. It is not intended for the end user.

VOFM is divided up into four main areas. These include copying requirements, data transfer, requirements, and formulas. This paper will focus on formulas that were delivered by SAP to support the Sales & Distribution (SD) and Logistics Execution (LES) applications. At a high level, formulas are routines that define how a value should be calculated or determined in the R/3 system.


For example, a pricing condition value formula allows the user to define how a specific pricing value should be calculated. Similarly, a rounding rule formula defines how rounding should take place when pricing mass maintenance is performed. Formulas are a powerful tool allowing the user to adjust the way in which the system determines certain values. They can also be used to set certain variables in the coding, or even to call other programs.

Creating a New VOFM Formula

In each area of VOFM, with the exception of Structure of Group Key Formulas, SAP delivers routines using the name space from 1 to 599. SAP customers can create their own VOFM routines using the name space from 600 to 999. With Structure of Group Key Formulas, the SAP name space is 1 to 49, and the customer name space is 50 to 99. To create a new routine, follow these steps:

  1. First check to see whether you can use one of the formulas delivered in the standard system.
  2. Either overwrite an existing formula or enter a new number on a new line from the customer name spac600 to 999. Also enter a short description of your formula.
  3. Program your formula in the ABAP editor.
  4. Activate the program.
  5. Enter the application if you want to use the formula in a specific application area.
  6. Enter your new formula in the appropriate area in customizing. For example, a new pricing condition value formula would be assigned to a condition type or value line in a pricing procedure. As another example, a fregoods calculation rule would be assigned to a free goods condition record. New VOFM routines created at customer site are not overwritten by a software upgrade.