Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Is there a Function to read the SD pricing-way complete

Florian
Active Contributor
0 Kudos

Hi all,

I'm looking for a function to read the complete pricing of a material.

You know, when I call the functions out of SD-pricing it gives me the first price it matches back. But what I'm looking for is a function to get the complete way of pricing and not just the last of matching.

Let me make an example to clarify my wish:

Article 100100 located in group BASIC

Basic price is 130€

All customer of it specific group BASIC it's 10 percent discount

For customer A,B and C it's got a fix-price 100€

When I use the pricing I get for costumer A just 100€ back and rest is gone.

I would have all options with it's specific things included.

I know, I can use the A-Tables and rebuild the structure by coding, but that can't be the solution. I mean, if there is something customized in a new way, the program has to be modified too.

Is there a function out there or did somebody got something custom made?

Regards

Florian

10 REPLIES 10

eduardo_hinojosa
Active Contributor
0 Kudos

Hi

Try with FM 'BAPI_SALESORDER_SIMULATE' and check the structure ORDER_CONDITION_EX .

I hope this helps you

Regards

Eduardo

Former Member
0 Kudos

Hi,

You can use FM 'MD_STOCK_REQUIREMENTS_LIST_API' to fetch your required output.

Thanks and Regards

Srimanta

Florian
Active Contributor
0 Kudos

Thanks for the answers so far, I will try those stones and give feedback.

~Florian

Former Member
0 Kudos

Hi,

You can build custom pricing report using transaction V/LA (V/L*).  You can do price simulation by calling the following two FM's in sequence.

1) SPR_KOMK_KOMP_FILL - Here, fill only the KOMK & KOMP structures. Basically you need to fill only those fields of KOMK & KOMP structures which are needed for pricing i.e all the key fields of condition tables.

If you want the price from the 5th table in the access sequence ,  fill  only the key fields of the 5th table , pricing date, material and sales area.

2) Call function 'PRICING'. Pass the KOMK & KOMP structures ( filled in previous step )..From the XKOMV table, get the price.

Also have a look at the following thread ,

Price List Report - Simulate a Pricing Procedure - Code Gallery - SCN Wiki

Regards,

DPM

0 Kudos

Hi Debopriyo,

thank you for the answer, but as mentioned before I need the hole chain of pricing. that is the point. I do not want to decide by my own, I just want to pass a article / customer-number and see every condition in every constalation which might be possible regarding to an price-schemata.

~Florian

0 Kudos

Hi Florian

If i am not wrong do you want to see how does the system arrived which condition to trigger as we see in pricing analysis button?

Thanks

Nabheet


0 Kudos

Here is a bit more information what I want to do.

I want to have a report that gives me a clue, what about a customer. I want to display all conditions which is available for this customer with all special conditions / normal conditions and stuff like that.

So that means, if he buys 1 item of the specific article it cost 100€, if he buys 10 of it the condition says 90€ and so on.

All this stuff I want to select dynamic, which means, I do not need to develop for every system an own program whcih is hard connected to the A-tables.

At the moment I collect all available stuff and test it. That's why I'm not able where all the stuff brings me and give a specific direction what I need at all.

~Florian

0 Kudos

Hi Florian

Thanks for providing the detail. For the scenario you have mentioned it looks like we are talking about scales. We had a look inside the system and found that in SPRO->SD->Basic Functions->pricing->Maintain PRiccing report. option already provide us the detail of condition type scales..discount etc

We can even customize this report and it shows us the details of pricing for different condition types

I hope i have understood your requirement correctly

Nabheet

0 Kudos

Hi nabheet,

I just want you to know that I'm figure it out at the moment if I can use multiple variants to create a proper merged result in the end.

Is there a possibility to do that via the customizing?

If I create a class, there might be some hard statements left and I have to recreate it, if I want to add some new variants.

~Florian

0 Kudos

Hi Florian

Thanks for the reply. To be honest i do not have much information about this customizing stuff  but yes we can even check the code which is done in background for them and then try to replicate it as per our requirement. Rather than variants i would have first checked if in backend SAP is using some FM etc then lets use that directly in our code.

Hope it helps

Nabheet