Rounding in BAQ

Gary,

Depending on your needs you might try expanding the decimal points to one more than you need and then use truncate() to drop the part you don't want.  

If you can't adjust the decimals another trick is to multiply it so that digits you want are in the integer part, drop the decimal and then convert back to the decimals you need.  You might need to do this to all components going into the calculation, do the math, drop the decimals from the result and then reconvert back.

Jim Kinneman
Encompass Inc

I made a calculated field in my BAQ, it is decimal field and three places.

It is rounding the output

How do you get the statement not to round the output?

 

Gary Wojtowicz

 

Did you change the mask? I think it defaults to something like 999,999.99. Something like that. Change the .99 to .999, I think. I can't recall exactly how it goes. Either that or something else. :-)

Joe

On Thu, Jan 7, 2016 at 3:53 PM, 'Gary Wojtowicz' gcw@... [vantage] <vantage@yahoogroups.com> wrote:

Â
<div>
  
  
  <p></p><div><p class="ygrps-yiv-1384229516MsoNormal"><i><span style="font-size:12.0pt;color:#943634;">I made a calculated field in my BAQ, it is decimal field and three places.<u></u><u></u></span></i></p><p class="ygrps-yiv-1384229516MsoNormal"><i><span style="font-size:12.0pt;color:#943634;">It is rounding the output<u></u><u></u></span></i></p><p class="ygrps-yiv-1384229516MsoNormal"><i><span style="font-size:12.0pt;color:#943634;">How do you get the statement not to round the output?<u></u><u></u></span></i></p><p class="ygrps-yiv-1384229516MsoNormal"><i><span style="font-size:12.0pt;color:#943634;"><u></u>Â <u></u></span></i></p><p class="ygrps-yiv-1384229516MsoNormal"><i><span style="font-size:12.0pt;color:#943634;">Gary Wojtowicz<u></u><u></u></span></i></p><p class="ygrps-yiv-1384229516MsoNormal"><u></u>Â <u></u></p></div><p></p>

</div>
 


<div style="color:#fff;min-height:0;"></div>

You can also use the round function – example - ROUND(AVGCOST * PartBin.OnhandQty, 2)

 

From: vantage@yahoogroups.com [mailto:vantage@yahoogroups.com]
Sent: Thursday, January 07, 2016 2:54 PM
To: vantage@yahoogroups.com
Subject: [Vantage] Rounding in BAQ

 

 

I made a calculated field in my BAQ, it is decimal field and three places.

It is rounding the output

How do you get the statement not to round the output?

 

Gary Wojtowicz

 

If I was to use the round statement it would round the calculation

I do not want to round the output, I would like the exact number

 

Gary Wojtowicz