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: 

More than one Minimum Value Charge on Invoice

jodi_yosko
Discoverer
0 Kudos

Our billing department wants to be able to implement tiered pricing by material pricing group, which is not a problem. I have that working. Then they tell me they want to this to work with minimum surcharges, which we already have working and I've already have it working with the tiered pricing for monthly billed customers using the programs in VOFM. But then they say, no, they want a Minimum Surcharge PER Material Pricing Group...and in our testing they have 3 tiered material pricing groups on one invoice. Has anyone done this before? I'm just thinking about all the data I'm going to have to be passing thru memory between the initial Function Module with the set up and then the VOFM programs. Whenever the programs run, there's never any way to know how many tables there will be. It's one thing to create one dynamically sized table but a dynamic number of multiple tables to pass is something else. I'd like to tell them it's not possible or limit them to the 3 material pricing groups that are in the test. Has anyone had any experience with this? I appreciate any advice from someone with more experience than I. Just want to be sure I'm thinking correctly and going down the right path, or there is a better way of doing it.

3 REPLIES 3

VXLozano
Active Contributor

Hi. Can you "de-elaborate" your question? I don't know what are you talking about, so my brain blocks itself while reading the text.
I assume you are asking for an algorythm, so, if you can reduce your question to basic data keeping out the (maybe) useless details, you'll have more chances for us to help you.

(or at least for me to understand your problem).
Something like: "I have n tables with x numerical fields, and I need to build m tables containing..." will do the job.

jodi_yosko
Discoverer
0 Kudos

Sorry for the confusion...I tend to write like I think. This is probably only the 2nd time I've posted in the 20+ years I've been in ABAP. Let me simplify.

Customer has 3 Material Pricing Groups. Each Material Pricing Group needs to have a Minimum Value (I called them surcharges before, which is incorrect). And all 3 of these Material Pricing groups need to appear on one invoice. For example, below....pretend the tiered pricing is working (because it is). Material Prc Group 1 has a Minimum value of $50, Material Prc Group 2 has a Minimum value of $100, Material Prc Group 3 has a Minimum value of $250 which was met. Each Minimum surcharge needs to be shown on the invoice. What I would like to know, has anyone ever had to do this before? I can figure out how to do it. I just want to know how many companies actually do this. After going thru my initial testing I was just wondering if anyone else was doing it.

Invoice Company XYZ

Mat Prc Group 1

Mat 1 $10

Mat 2 $20

Mat 3 $10

Mat Prc Group 2

Mat 4 $10

Mat 5 $10

Mat Prc Group 3

Mat 6 $40

Mat 7 $60

Mat 8 $50

Subtotal $ 210

Mat Prc Grp 1 Min Surcharge $ 10

Mat Prc Grp 2 Min Surcharge $ 80

Total $ 300

VXLozano
Active Contributor

Heh, you added an answer by writing directly into "Your answer" box 😛
Next time, use the "add a comment" link under the question XD

I am not sure what the f... your company sells, but o my, I will not buy it if I have to pay for non-bought items.

Anyways, the logic seems pretty straightforward, the only thing you must take under consideration is how to make it flexible. I suppose you'll be using a Z table per mat group (if that "group" is not a standard thing, I'm no consultant). The rest is a piece of cake 🙂

Good luck, mate, and thanks for the explanation, I was wondering what all that text meant XD