Skip to main content
Announcements
Accelerate Your Success: Fuel your data and AI journey with the right services, delivered by our experts. Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
OmarBenSalem

Number format

Hi folks,

I'm trying to format my numbers in the SCRIPT.

here's how they're now:

Capture.PNG

and I want them to be as follow:

Capture.PNG

For that, I've done as follow:

num(Current_Notional,'# ##0') as Current_Notional,


and

num(num#(Current_Notional),'# ##0') as Current_Notional,

But, this did not change a thing !

What am I doing wrong?

15 Replies
Chanty4u
MVP
MVP

for time being i tested with one value   it worked

OmarBenSalem
Author

Ah no ! that also did not work !

It includes all the numbers; I mean the result will be :

like Current_Notional instead of current

Capture.PNG

to achieve the current value:

here's what I've done :

num(SubField(Current_Notional,',',1),'# ##0','.',' ') as current,

OmarBenSalem
Author

my bad ! when I tested this another time; this is what really works as I want !

Chanty4u
MVP
MVP

Ohh is it !!!!   its nice have a nice day

Chanty4u
MVP
MVP

other way i think is that  you can remove the separator values in

envvironment variables for  thousnd and money like depends on your requriment and check

its not tested,

OmarBenSalem
Author

what really confuses me is :

when I use :

Num#( Field, '#', ' ', ' ') as Field

or

num(Num#( Field, '#', ' ', ' '),'# ##0') as Field,

It does not work as I want to !

But, if instead I change the Field Name; it does work !!

Num#( Field, '#', ' ', ' ') as Field2

or

num(Num#( Field, '#', ' ', ' '),'# ##0') as Field2