cancel
Showing results for 
Search instead for 
Did you mean: 

Pricing condition based on external data

christiannicolas
Explorer
0 Kudos

SD is not my home base, so maybe some experts can help to jumpstart how to solve the following requirement:

I have several materials, which are sold via an SD-order: FIN1, FIN2, ...

In a customer table for each SD-order I have a long string (up to 400 digits), e.g.

SD-Order Material String

1 FIN1 “abdefijjloq”

2 FIN2 “acdefgxyz”

3 FIN1 “fghijmno”

If in this string there is a specific partial string included then the following condition should be checked if they are applicable and then used:

String Condition Material Value Currency

“g” ZKO1 FIN1 30 USD

“g” ZKO1 FIN2 40 USD

“z” ZKO2 FIN2 15 USD

So the result would be:

SD-Order 1: nothing

SD-Order 2: ZKO1 40 USD, ZKO2 15 USD

SD-Order 3: ZKO1 30 USD

Can I use an user-exit? Do I have to use variant conditions? If someone could point me in the correct direction, that would greatly help!

Christian

Accepted Solutions (0)

Answers (3)

Answers (3)

Lakshmipathi
Active Contributor
0 Kudos

You need to add the string field to pricing catalogue with the help of USEREXIT_PRICING_PREPARE_TKOMK / USEREXIT_PRICING_PREPARE_TKOMP for both sale orders and billing. This has been explained in OSS note 1456169. Once this is done, via condition record, it is quite possible to determine the required pricing in billing

christiannicolas
Explorer
0 Kudos

that sounds promising, I will check that out.

but I need a little bit of time until can give an update here.

Thank you very much for the quick help !!!

Lakshmipathi
Active Contributor
0 Kudos
only if in the connected customer table 
(or userfield in SD order)

Your above two statements are not clear. Are those two data maintained in SAP ? I don't think so. Please share more information on how currently, the sale order is being processed

christiannicolas
Explorer
0 Kudos

I try to explain it with three SD-orders:

in the first one the material FIN1 is sold with condition PPR0 = 1000 USD. In a customer field in table VBAK a string is stored. If this string includes "g" an addtiinonal price condition ZK01 should be found to bill additional 30 USD for the combination "FIN1 with g"

the second customer order material FIN2 is sold with condition PPR0 = 2000 USD and the string in the customer fields also includes "g", but now for the combination "FIN2 with g" for ZK01 40 USD should be determined.

The third customer sells material FIN2 with condition PPR0 = 2000 USD but in the string there is no "g", so condition ZK01 should not be found, but it inlcudes "z", and now condition ZK02 with 15 USD should be found.

I hope I could make myself clear here.

Lakshmipathi
Active Contributor
0 Kudos

In material master, you can differentiate such of those materials either with Material Group and Material Pricing Groups. If you are able to achieve this, then, it is easy to achieve your pricing as just you need to have the related access sequence in your condition record.

christiannicolas
Explorer
0 Kudos

but the condition should not always be found for a specific material, only if in the connected customer table (or userfield in SD order) a specific entry exists (I think this is more like a configuration)