SAP Documents
SAP.

Monday, May 18, 2009

SAP Tutorial - Part 16 - Sales & Distribution - Pricing - Part 3

Material Master Price as Sales Price Automatically


The first method is not to set the pricing condition VPRS as statistical.

Simply remove PR00 and it will work fine if you always use VPRS as your pricing base inside the pricing procedure.

VPRS will reads both prices based on the price control in the material master.

Price control S for standard price.
Price control V for moving average price.

It is this simple if you do not have any other "Prices" in the price procedure.



Steps to Create Commission for Agent


For creating commission agent, you have to follow below steps.

1) Establish Partner Functions for the Commissionee(s)
Menu Path: TOOLS ->; BUSINESS ENGINEER ->; CUSTOMIZING ->; SALES AND DISTRIBUTION ->; BASIC FUNCTIONS ->; PARTNER DETERMINATION ->; DEFINE PARTNER FUNCTIONS
Transaction Code: VOPA

2) Assign the Partner Functions to Partner Procedures
Menu Path: TOOLS ->; BUSINESS ENGINEER ->; CUSTOMIZING ->; SALES AND DISTRIBUTION ->; BASIC FUNCTIONS ->; PARTNER DETERMINATION ->; DEFINE PARTNER FUNCTIONS
Transaction Code: VOPA

3) Create a Partner Procedure for the Commissionees
Menu Path: TOOLS ->; BUSINESS ENGINEER ->; CUSTOMIZING ->; SALES AND DISTRIBUTION ->; BASIC FUNCTIONS ->; PARTNER DETERMINATION ->; DEFINE PARTNER FUNCTIONS
Transaction Code: VOPA

4) Create New Customer Account Group(s) for Commission Agents
Menu Path: TOOLS ->; BUSINESS ENGINEER ->; CUSTOMIZING ->; LOGISTICS GENERAL ->; LOGISTICS BASIC DATA: BUSINESS PARTNERS ->; CUSTOMERS ->; CONTROL ->; DEFINE ACCOUNT GROUPS AND FIELD SELECTION FOR CUSTOMER
Transaction Code: OVT0

5) Assign the Partner Functions to the Customer Account Group(s)
Menu Path: TOOLS ->; BUSINESS ENGINEER ->; CUSTOMIZING ->; SALES AND DISTRIBUTION ->; BASIC FUNCTIONS ->; PARTNER DETERMINATION ->; DEFINE PARTNER FUNCTIONS ->; GOTO ->; PARTNER FUNCTIONS ->; ENVIRONMENT ->; ACCOUNT GROUP ASSIGNMENT
Transaction Code: VOPA

6) Assign the Partner Functions to the Partner Procedure for the Sales Document Header
Menu Path: Tools ->; Business Engineer ->; Customizing ->; Sales and Distribution ->; Basic Functions ->; Partner Determination ->; Define Partner Functions
Transaction Code: VOPA

7) Assign the Partner Functions to the Partner Procedure for the Sales Document Item (OPTIONAL)
Menu Path: TOOLS ->; BUSINESS ENGINEER ->; CUSTOMIZING ->; SALES AND DISTRIBUTION ->; BASIC FUNCTIONS ->; PARTNER DETERMINATION ->; DEFINE PARTNER FUNCTIONS
Transaction Code: VOPA

8) Edit the Pricing Communication Structure (KOMKAZ) to Hold the New Functions (Client Independent)
Menu Path: Menu Path: TOOLS ->; ABAP WORKBENCH ->; DEVELOPMENT ->; DICTIONARY
Transaction Code: SE11

9) Edit MV45AFZZ – userexit_pricing_prepare_tkomk (Client Independent)
Menu Path: TOOLS ->; ABAP WORKBENCH ->; DEVELOPMENT ->; ABAP EDITOR
Transaction Code: SE38

10) Edit RV60AFZZ - userexit_pricing_prepare_tkomk (Client Independent)
Menu Path: TOOLS ->; ABAP WORKBENCH ->; DEVELOPMENT ->; ABAP EDITOR
Transaction Code: SE38

11) Edit MV45AFZB - userexit_new_pricing_vbkd changing new_pricing (Client Independent)
Menu Path: TOOLS ->; ABAP WORKBENCH ->; DEVELOPMENT ->; ABAP EDITOR
Transaction Code: SE38

The following code should be inserted into program MV45AFZZ to allow the system to re-execute pricing if the user makes a change to the relevant partner function (alteration, addition, deletion).

13) Add the KOMKAZ Fields to the Pricing Field Catalog (Client Independent)
Menu Path: TOOLS ->; BUSINESS ENGINEER ->; CUSTOMIZING ->; SALES AND DISTRIBUTION ->; BASIC FUNCTIONS ->; PRICING ->; PRICING CONTROL ->; DEFINE ACCESS SEQUENCES ->; MAINTAIN ACCESS SEQUENCES
Transaction Code: OV24

14) Create Condition Tables (Client Independent)
Menu Path: TOOLS ->; BUSINESS ENGINEER ->; CUSTOMIZING ->; SALES AND DISTRIBUTION ->; BASIC FUNCTIONS ->; PRICING ->; PRICING CONTROL ->; DEFINE ACCESS SEQUENCES ->; MAINTAIN ACCESS SEQUENCES
Transaction Code: V/03

15) Create an access sequence containing the new tables (Client Independent)
Menu Path: TOOLS ->; BUSINESS ENGINEER ->; CUSTOMIZING ->; SALES AND DISTRIBUTION ->; BASIC FUNCTIONS ->; PRICING ->; PRICING CONTROL ->; DEFINE ACCESS SEQUENCES ->; MAINTAIN ACCESS SEQUENCES
Transaction Code: V/07

16) Create a new condition type
Menu Path: TOOLS ->; BUSINESS ENGINEER ->; CUSTOMIZING ->; SALES AND DISTRIBUTION ->; BASIC FUNCTIONS ->; PRICING ->; PRICING CONTROL ->; DEFINE CONDITION TYPES ->; MAINTAIN CONDITION TYPES
Transaction Code: V/06

17) Add the Condition Type to the Pricing Procedure
Menu Path: TOOLS ->; BUSINESS ENGINEER ->; CUSTOMIZING ->; SALES AND DISTRIBUTION ->; BASIC FUNCTIONS ->; PRICING ->; PRICING CONTROL ->; DEFINE AND ASSIGN PRICING PROCEDURES ->; MAINTAIN PRICING PROCEDURES
Transaction Code: V/08

11) Create Commission Report ZZCOMMISSION (Client Independent)
Menu Path: TOOLS ->; ABAP WORKBENCH ->; DEVELOPMENT ->; ABAP EDITOR
Transaction Code: SE38




However, if you are using one pricing procedure where for some items you price using VPRS and some others using PR00, then you should use requirement routines to enable the correct price condition type at the right time.

The second method involves more work as you need to write a formula (VOFM) to get that information.

This is how it goes :-

1. Set VPRS to be the first step in the pricing procedure and to be subtotal B (as standard).

2. Set PR00 with alt. calc. type formula, which sets the value of PR00 to be equal to the subtotal B.
The routine (created with transaction VOFM) is:

RV64A901
FORM FRM_KONDI_WERT_600.
XKWERT = KOMP-WAVWR.
ENDFORM.

The pricing procedure than looks like that:

Step 1 VPRS statistical, subtotal B, reqt 4
Step 2 PR00 Altcty 600

No comments: