Applying Discount To The Unit Price, Not Line Value

Jonathan2708
Member Posts: 552
Hi,
I have a customer who for marketing reasons wants to have the line discount % applied to the unit price instead of the line value. I have suggested I just show this as the 'Net Price' using a formula field on the sales order report to give an indicative price but they insist on having it shown, calculated and posted using 2 decimal places. For example :
Current Method (Standard Navision)
New Method
Here the Net Price is actually 54.495 rounded to 2 decimal places which has the effect of increasing the line value.
Unless I'm missing something it seems to me that to do this I would have to re-write all the unit price/discount/VAT line value calculations in Navision to work under this method which I'm really not keen to do.
Has anybody else done this as a modification or has any suggestions?
Any help appreciated,
Jonathan
I have a customer who for marketing reasons wants to have the line discount % applied to the unit price instead of the line value. I have suggested I just show this as the 'Net Price' using a formula field on the sales order report to give an indicative price but they insist on having it shown, calculated and posted using 2 decimal places. For example :
Current Method (Standard Navision)
Qty Price Disc % Line Value After Disc 6 72.66 25 326.97
New Method
Qty Disc % Net Price Line Value 6 25 54.50 327.00
Here the Net Price is actually 54.495 rounded to 2 decimal places which has the effect of increasing the line value.
Unless I'm missing something it seems to me that to do this I would have to re-write all the unit price/discount/VAT line value calculations in Navision to work under this method which I'm really not keen to do.
Has anybody else done this as a modification or has any suggestions?
Any help appreciated,
Jonathan
0
Comments
-
they want this to show on the sales line or in some report?
how about something like this
if Qty = 0
then "Net Price" := 0
else "Net Price" := "Line Value" / Qty
**edit**
I see you mentioned a formula already..where do they want this shown?0 -
The rounding should not have impact on the line amount. Then you can keep standard functionality and you can update your net price field in the end of the updateamounts function.0
-
Why not using 3 decimal places for the Unit Price, and only 2 decimals for the line amount? That way, you are going to have the same amount in both cases.0
-
Hi,
Thanks for the replies, I've decided to add code to recalculate the Unit Price column to 4/5 decimal places so that it gives the same line value when the discount is applied to the line as it does if the discount is applied to the unit price.
Jonathan0 -
Please be very careful if you intend to change the Unit Price calculation on the Sales Line. You are going to change Navision logic. I would recomend you to leave it as is, only changing the number of decimals, and to change the Unit Price calculation only on the reports (Order Confirmation, Invoice, Credit Memo).
In my country we are using for the discount calculation exactly the same logic as you want to implement. In the beginning I was tempted to change the logic, but after looking in more depth at the possible consequences, I have decided the safest way is to avoid changing the logic.0 -
Nothing wrong with changing the logic of the codeunit if you do it right.0
-
Right Mbad. But, if I have to choose between making a major change in the logic of Navision (and it is not only one codeunit to change), and making some minor changes in three reports, I would always choose the latest option. Which is also the safest solution. Or maybe I am a lazy person.0
-
Yup i would just change the reports too. Guess your not lazy after all :-)0
-
This has caused us many, many problems in the past as well.
We have added far too many fixed 'Sales Prices' to counteract this calculation.
What I have done is increase the decimal places so that the calculation of the line value will be consistant with that of the (virtual) 'Unit Price'.
I am ready to make the changes in our production database but I have one remaining problem ... is Navision rounding down??
For example:Qty Price Disc % Line Value After Disc 2 4.15 35 5.39
Why is this not $5.40 ?? ](*,)
(2 * 4.15) * ((100-35)/100) = 5.395
8.30 * 0.65 = 5.395
Thanks for your help,
headley270
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions