Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Substring

Hi All,

How to search a substring is present or not in a given string besides using wildmatch function.

7 Replies
tamilarasu
Champion
Champion

Hi Satej,

You can use Like function as an alternate.

If( Field Like '*Substring*',1,0)

You can also use Index function.

If(Index( Field, 'Substring' ),1,0)

tresesco
MVP
MVP

Or,

Substringcount()  , like:

substringcount( text , substring)

Returns the number of times the string substring appears within the string text. The result is an integer. If there is no match, 0 is returned

Example:

substringcount ( 'abcdefgcdxyz', 'cd' ) returns 2

I.e. - if the function returns value>0, then the substring is present else not.

Anonymous
Not applicable
Author

Thanks buddy

Anonymous
Not applicable
Author

thank you

antoniotiman
Master III
Master III

oknotsen
Master III
Master III

If your question is now answered, please flag the Correct Answer (via the big "Correct Answer" button near every post) and Helpful Answers (found under the Actions menu under every post).

If not, please make clear what part of this topic you still need help with .

May you live in interesting times!