Hi
I am building some kind of portfolio tracker for investment. For easier explanation, let’s say it’s for crypto currencies
I have a table where there are list of coins with some details such as current price and average price in another columns.
So there are prices everywhere on my frontend.
The problem here is some coins do not need lots of decimal (e.g. 104.24) whereas prices of some coins are like 0.0609121.
So when I display those prices, for some coins it will look like 104.240000, 1405.000000, just because there are coins like 0.0223422.
How can I solve this issue? so that it would look like 104.24, 1405.0, 0.0223422.
You can also place the value in an if then else column. Only caveat is that null values need to have some sort of string value (even a space will work)
The ITE columns attempts to return a value of the same type as the inputs. When all the types match, it outputs a value of that same type. When the types don’t match (in your case. A number with a fixed decimal place and a string value) it outputs a string.
Now that I’m thinking about it, a template column works the same way if you specify the number column as the input…