Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to make 430 / 0.65 = 661 ?

Hi All

may i know how to make my selling price = 661.5 ? now display as 656.5

661.png

1 Solution

Accepted Solutions
jerem1234
Specialist II
Specialist II

This formula gets you the 661.50:

floor(ceil(FOB_SGD_SUB*RATE_P/LESS,.5)/MARKUP_SUB, .5)

But I didn't use your field TRANSPORT_SUB cause I am not sure how this factors in. Also its not as perfect as 430/.65. The equation FOB_SGD_SUB*RATE_P/LESS gives you a decimal value, in which you use ceil to make it become 430 in the previous expression. However you didn't do any rounding to it in:

Ceil(FOB_SGD_SUB*RATE_P*TRANSPORT_SUB/MARKUP_SUB*LESS,0.5)

So it is using the decimal value and not the actual value 430 (also you are multiplying TRANSPORT_SUB to it in your equation, which is throwing your number off).

That is why I rounded, then divided:

floor(ceil(FOB_SGD_SUB*RATE_P/LESS,.5)/MARKUP_SUB, .5)

Also, the value is larger than 661.5, so if you use ceiling, it will round to 662 (which is why i used floor).

I can't be sure what numbers you are actually expecting.

Hope this helps!

View solution in original post

4 Replies
Not applicable
Author

Hi All

I forget to info , Table (A) have cal error only when user select TMY or TID or TTH.

When user select TSG the calculation is correct.

kindly use my below QV doc.

237.png

rbecher
MVP
MVP

..because LAND_COST_TDS_SGD <> FOB_SGD_SUB*RATE_P*TRANSPORT_SUB*LESS for TMY

Astrato.io Head of R&D
jerem1234
Specialist II
Specialist II

This formula gets you the 661.50:

floor(ceil(FOB_SGD_SUB*RATE_P/LESS,.5)/MARKUP_SUB, .5)

But I didn't use your field TRANSPORT_SUB cause I am not sure how this factors in. Also its not as perfect as 430/.65. The equation FOB_SGD_SUB*RATE_P/LESS gives you a decimal value, in which you use ceil to make it become 430 in the previous expression. However you didn't do any rounding to it in:

Ceil(FOB_SGD_SUB*RATE_P*TRANSPORT_SUB/MARKUP_SUB*LESS,0.5)

So it is using the decimal value and not the actual value 430 (also you are multiplying TRANSPORT_SUB to it in your equation, which is throwing your number off).

That is why I rounded, then divided:

floor(ceil(FOB_SGD_SUB*RATE_P/LESS,.5)/MARKUP_SUB, .5)

Also, the value is larger than 661.5, so if you use ceiling, it will round to 662 (which is why i used floor).

I can't be sure what numbers you are actually expecting.

Hope this helps!

Not applicable
Author

Hi Jerem123

Yes , you very smart . now it work fine.  Doing QV like play chess game. Mind must be very clear and steady to cal every step move.  and then modify the expression as you wish. Last night i just cannot figure out how to make it work....

Many thank.

Paul