Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Need Help Formatting Decimals

RyanA20
5 - Atom

Hello, I am trying to format the following data set and can’t seem to get anything to work any suggestions?

 

 

Input:          Desired Output:

11,578.9             11,578.90

1,655                    1,655.00

765.3                       765.30

8,440.86.              8,440.86

 

I currently have it formatted as a Fixed Decimal (254.2) so it will return up to 2 decimal places, but only if the input originally had any decimals and will not expanded out to 2 decimal places if no value was there for the input

3 REPLIES 3
apathetichell
19 - Altair

O.k. so there is no way to do this with a number but there are work-arounds:

 

1) The table way. If using a table/render output system you can manually set 2 as the number of decimal places for the column and it WILL render as a number to excel and present in a table with proper formatting.

 

2) the convert to string and pad with 0 ways. It's a string. You get the number of zeros after the decimal (or if it has a decimal) and then pad it with two zeros. The disadvantages: It's now a string. It can't be used for math.

 

Note  - this is a semi-bug for some users where fixed with doesn't do what it is supposed to do. I have this bug. I theorized it may have something to do with commas as thousands separators being turned on so you can try to toggle that/exit/reload etc and see if it might work.

messi007
15 - Aurora
15 - Aurora

@RyanA20,

 

Please see below:

messi007_0-1620372152868.png

Attached the workflow,

Hope this helps!

Regards,

RyanA20
5 - Atom

@messi007 Thank you so much for the help!

Labels