Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Interge and Decimal

how do you get the whole number and then the decimal?

Example: 1500.90

I want only what is before the point and then just what is the point after.

Result: 1500

Result: 90

thank you

2 Replies
goldnejea8
Partner - Creator
Partner - Creator

Try something like this

subfield(NUMBER,'.',1) as [Before Decimal]

subfield(NUMBER,'.',2) as [After Decimal]

goldnejea8
Partner - Creator
Partner - Creator

And if you need to make sure it is still a number after the fact, you could try something like this:

num(subfield(NUMBER,'.',1),'# ##0,#') as [Before Decimal]

num(subfield(NUMBER,'.',2),'# ##0,#') as [After Decimal]