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: 
pascos88
Creator II
Creator II

extract a string between 2 specific character

iDear Expert, 

do you know if there is a way to extract a string between two specific characters? 

row1 : ' year=2017, name=Peter, surname=Jon,  address= herenstrasse ' 

row2 : ' surname=Dario, name=Andrea , address= boundstrasse

I would like to extract for instance all the surname in my table. The order or the data in the string can be casual

Thanks for any helps 

 

 

 

1 Solution

Accepted Solutions
Frank_Hartmann
Master II
Master II

try this:

textbetween(YourFieldName,'surname=',',') as Surname

View solution in original post

2 Replies
Frank_Hartmann
Master II
Master II

try this:

textbetween(YourFieldName,'surname=',',') as Surname

mdmukramali
Specialist III
Specialist III

Hi,

can you try something like this:

=SubField( Mid(YourField,Index(YourField, 'surname')+8) ,',',1)
example:

=SubField( Mid('year=2017, name=Peter, surname=Jon, address= herenstrasse',Index('year=2017, name=Peter, surname=Jon, address= herenstrasse', 'surname')+8) ,',',1)

2.

=SubField( Mid('year=2017, name=Peter, surname=Jon, address= herenstrasse',Index('year=2017, name=Peter, surname=Jon, address= herenstrasse', 'surname')+8) ,',',1)


Thanks,
Mohammed Mukram