Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Function for strem !!!

Hi everyone:

Someone do you know some function that get the last stream that have for example the word 'CM' to the finally

for example:

items:

123456CM

a12d13x1x1CM

1234567810

wert12345678

CM 123456456

a1d3f5g6h6CM

aw-CM

I need Just the records that have in finally of the stream the word 'CM' please JUST only in the FINALLY  the word 'CM'

in the last example I need just:

123456CM

a12d13x1x1CM

a1d3f5g6h6CM

aw-CM

thanks can you help me!!!

Regards!!!

1 Solution

Accepted Solutions
Not applicable
Author

I was looking for and the solution is:

where WildMatch(item, '*CM')

in this way I will have all records in the final have the word 'CM'

thanks very much for your help.

regards!!

View solution in original post

6 Replies
its_anandrjs

Use Index function

Ex:-

Tab1:

LOAD * INLINE [

    items

    123456CM

    a12d13x1x1CM

    1234567810

    wert12345678

    CM 123456456

    a1d3f5g6h6CM

    aw-CM

] Where Index(items,'CM');

And you get output as

123456CM

a12d13x1x1CM

a1d3f5g6h6CM

aw-CM

its_anandrjs

Another one is

Tab1:

LOAD * INLINE [

    items

    123456CM

    a12d13x1x1CM

    1234567810

    wert12345678

    CM 123456456

    a1d3f5g6h6CM

    aw-CM

];

NewTable:

LOAD

items,

items as [CM items]

Resident Tab1

Where Index(items,'CM');

Not applicable
Author

thanks a lot but the index in this way just get all records that have "CM" in any part of the stream that I need is all records to the finally it have 'CM' but any way I find the solution it's too easy but anand chouhan thanks for your help!!!!

regards

jerem1234
Specialist II
Specialist II

If CM is always the last two letters, then you can use the conditional:

right(items, 2)='CM'

Hope this helps!

Not applicable
Author

I was looking for and the solution is:

where WildMatch(item, '*CM')

in this way I will have all records in the final have the word 'CM'

thanks very much for your help.

regards!!

Not applicable
Author

this way is correct also thanks