I need help with a calculation.
I have a price field and a current price field. We will be lowering our price by 5 % and that becomes our current price.
current price = price - 5%
CurrentPrice = OldPrice * 0.95
CurrentPrice * 0.95
Only thing to think about here is use of the calculation..
i.e what happens to price when you want to remove the discount? Do some orders need the discount and others do not? Do you need to keep history of when and to what the discount was applied?
This is a straight forward discount, nothing complicated.
Give some thot to not hard-coding the 0.95 into your formula. Instead create a global field (which I'll call DiscountRate) and use the formula
CurrentPrice = OldPrice * (1 - DiscountRate)
Then, any time you want to drop the discount, you just revert the contents of the DiscountRate field from .05 to 0. Next time you want to give a discount (say, 3%), you enter .03 in that field, and you're good to go again without ever having to poke around under the covers.
Everything is straightforward and simple until the owner has a new idea...
You might include an on off checkbox field, Apply Discount.
Then the calc can be made:
If apply discount = yes
old price * .95
and one more step a discount field = xx5
old price * (100-discountfield)
These two fields add a bit of value to the process...
Retrieving data ...