Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
qlikuser222
Creator
Creator

extract numericals?

Hi All,

I have filed values like

Start - 6 Days

Not Start - 7 Days

can any on please How can I extract numerical from the above field values??

Thanks

Labels (1)
1 Solution

Accepted Solutions
swuehl
Champion III
Champion III

Just to offer another option (and there are lot more, have a look at the QV string functions in the HELP), depending on your exact requirements:

LOAD *,

  KeepChar(Text,'0123456789') as Number1,

TextBetween(Text, '-','Day') as Number2;

LOAD * INLINE [

Text

Start - 6 Days

Not Start - 7 Days

Started to early - -1 Day

2 times started - 2 Days

Worked part time - 0.5 Days

];

Text Number1 Number2
Start - 6 Days6 6
Not Start - 7 Days7 7
Started to early - -1 Day1 -1
2 times started - 2 Days22 2
Worked part time - 0.5 Days05 0.5

View solution in original post

2 Replies
sunny_talwar
MVP
MVP

Try this:

KeepChar(FieldName, '0123456789') as NewFieldName

swuehl
Champion III
Champion III

Just to offer another option (and there are lot more, have a look at the QV string functions in the HELP), depending on your exact requirements:

LOAD *,

  KeepChar(Text,'0123456789') as Number1,

TextBetween(Text, '-','Day') as Number2;

LOAD * INLINE [

Text

Start - 6 Days

Not Start - 7 Days

Started to early - -1 Day

2 times started - 2 Days

Worked part time - 0.5 Days

];

Text Number1 Number2
Start - 6 Days6 6
Not Start - 7 Days7 7
Started to early - -1 Day1 -1
2 times started - 2 Days22 2
Worked part time - 0.5 Days05 0.5