Help between Notion users

It's free & easy

Receive points, vote and give the solution

0vote

# Limit number of decimals in Notion formula

I have a simple formula an I want to show only 2 decimals in the result.

Income: \$1,502.72
Expense: -\$71.00

``format(abs(prop("Income") + prop("Expense")))``

Result: \$1431.720000000001

Changing it to ceil, round or floor removes all decimals and I am trying to show only 2 decimals like this:

\$1431.72

How can I do that?

0vote

Saritanotion Points1020

When a Formula property returns a number, it can contain numerous decimals. Here’s an easy way to specify the number of decimals.

Start with a database containing a Formula property with too many decimals.
Determine your modifying number. For your final output to contain one decimal, use 10; for two decimals, use 100. (Add a zero for each decimal place.)
Multiply the full formula by your modifying number. (You may need to wrap the existing formula in parenthesis. PEMDAS)
Surround the new formula with the round function.
Divide that new formula by your modifying number.

0vote

### nosy commented Jul 19, 2022

Can you please share an example using the information from the question?

Thanks.

0vote

polle Points79930

Not sure if you are still facing this Notion problem with decimals, but try the following formula using yours as an example.

``format(round(abs(prop("Income") + prop("Expense")) * 100) / 100)``

Hope that helps.

...