Enterprise Resource Planning Blogs by Members
Gain new perspectives and knowledge about enterprise resource planning in blog posts from community members. Share your own comments and ERP insights today!
Showing results for 
Search instead for 
Did you mean: 
Active Contributor

Recently I am on a project. In this project, we had a challenge.

In their business, they have 61 plants (for three company codes) and they are using stock transport order from 5 manufacturing plants to all those 56 plants (basically called Depots).

They are using a transfer price for each stock transport order. Transfer price is nothing just a condition type is added into schema and amount will be fetched automatically from condition record.

They have over 20k material and they have 7 different price as per different locations. Multiple plants is exist for one location. They have categorized all plants into 7 different price lists.

First we have tried to map condition record by using combination Receiving plant and Material. But then we realized that condition record has to be maintained 56 times for all 20k materials. It’s really a tough job for user to maintain price for 56 times for 20k materials.

Basically, their requirement was to categorized plant with regards to price list. So we did need to find a field which can be assigned to multiple plants (with same value) and this field can be used for price determination. Unfortunately we did not find any such field.

Then we found an option to map their requirement. A customer (plant as customer) need to be assigned to plant in case of stock transport order. We take the field Price list (PLTYP) from customer master as a category of those customers which are assigned to certain plants.

Note: They were not using that field (Price list) in SAP system.

Price list is available in field catalogue for MM pricing. If not, then you can add it from OLME-Conditions-Define Price Determination Process-Extend Field Catalog for Condition Tables.

Then create a new condition table from M/03:

Then add this condition table to certain access sequence from M/07. Then use this access sequence for that certain condition type.

These were the configuration done from functional side (for clear information, you can check this blog post Pricing procedure Steps and Details in SAP MM). Now one enhancement has to be done from technical side.

We need to pass the price list value to KOMK and KOMP structure by using enhancement LMEKO001 - Extend communications structure KOMK for pricing and LMEKO002 - Extend communications structure KOMP for pricing.

Coding part is:

DATA: lv_kunnr TYPE kna1-kunnr.
IF i_ekko-bsart = 'ZUB'.

   SELECT SINGLE kunnr FROM t001w
     INTO lv_kunnr
     WHERE werks EQ i_ekpo-werks.
   IF sy-subrc EQ 0.
     SELECT SINGLE pltyp FROM knvv
       INTO e_komp-pltyp_p
       WHERE kunnr EQ lv_kunnr
       AND   vkorg EQ i_komk-vkorg
       AND   vtweg EQ i_komk-vtweg
       AND   spart EQ i_komk-spart.


We have made it for ZUB document type only (you can do it for UB document type also), so that it wont take effect for any other process (like Inter company STO). In that coding you can see we have taken KUNNR from T001W table and take the price list (PLTYP) value from KNVV table with certain selection criteria (like Sales organization, Distribution channel and Division) and pass the value to certain structure.

Note: You have to do this coding for both enhancement (LMEKO001 and LMEKO002).

Now take those assigned customers from T001W table and categorized these customers (plant as customers) with certain value in Price list. E.g. S1 - Sales Price_West Bengal, S2 - Sales Price_Delhi, S3 - Sales Price_Mumbai etc. You can find it in sales view of customer master record:

Now create condition record by using this condition table from MEK1:

Now create stock transport order where be sure you are using correct receiving plant, as customer (plant as customer) will be fetched from shipping data of particular receiving plant.

Here, you can see Transfer price has come automatically with correct price which we have maintained in condition record. In shipping tab, you can find the same customer code.

Now they are happy with that. They just need to maintain condition record for 7 price list and it will be effected for all 56 plants.

I have given an example to use the field Price List (PLTYP), you can use any other field. Just remember, that field has to be exist in price field catalog.