Function for price calculation in purchasing
For reporting reasons only, I need to find a function that receives as an input
1. contract no.
2. material no.
and calculates the relevant price taking under consederation all above factors (in the contract we have scales, discounts, deiferent validity periods of prices etc).