Hi, Hopefully a quick one, I created a formula for a percentage figure, but it is coming out to 5 or 6 decimal places, I would like this to be 2 decimal places, is there anything I can add to the formula to achieve this in Jet?
Thanks
5 comments
-
Jet Reports Historic Posts Official comment Hello clipif.
From the formula it looks like you are using a table. Please take a look at the attached report. I was able to get the values to round using the ROUND function. I also have an IFERROR function to get rid of divide by zero errors. =NP("Formula","=IFERROR(ROUND([@[Balance]]/[@[Payments]],2),0)")
I hope this helps.
Jason
Book3.xlsx -
Jet Reports Historic Posts You should be able to format the cell in Excel. As long as you make the change in Design mode, it should retain the Excel formatting.
-
Jet Reports Historic Posts You can also round the result using an Excel formula that wraps around your Jet formula: =ROUND([jet formula], 2). The 2 in this example is the number of decimal places that you want to round to.
-
Jet Reports Historic Posts Unfortunately neither worked.
for JET-btr I tried this, but when the report was run the output was changed back to General even though in Design mode it was number & 2 decimal places?
User-Jill I get an error with adding the round function - =ROUND(NP("Formula","[@[Cust Margin]]/[@[Unit Price]]*100"), 2) is this the correct format? I get an error - the pivottable1 could not be refreshed, the following error was reported: Reference is not valid -
Jet Reports Historic Posts Thanks JasonT I managed to do it, with you help, my final formula was =NP("Formula","=ROUND(([@[Cust Margin]]/[@[Unit Price]]*100),2)") so it is user error/experience on getting the formula correct,
cheers