Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
patriciousa
Creator II
Creator II

New field bases on specific value in cell/text

Hi community.

I need to do a new field on the load tab with the following data:

Name
asdaddsaDONT USE
asdDONT USEasd
DONT USEasdsasd
asdsaddadasdsadsa
asddsadsad
asd(DONT USE!)asddas
OPENasdasd
asddsaOPENasdsad

The fields I need would be "Name DONT USE" and "Name Open".

If the words DONT USE or OPEN would be at the beggining or the end I would use =RIGHT or =LEFT but it is not the case.

I have tried using if(wildmatch)) but I'm not doing it correctly.

Any help would be appreciate.

Thank you in advance.

Regards.

1 Solution

Accepted Solutions
Anonymous
Not applicable

Yes it's case sensitive. You can use the upper function to put your field in capital letters.

if(SubStringCount(upper(Name),'DONT USE')>0,'DONT USE',if(SubStringCount(upper(Name),'OPEN')>0,'OPEN',))

View solution in original post

4 Replies
Anonymous
Not applicable

Hi,

you can use SubStringCount() function like this :

if(SubStringCount(Name,'DONT USE')>0,'DONT USE',if(SubStringCount(Name,'OPEN')>0,'OPEN',))

patriciousa
Creator II
Creator II
Author

Thank you Anne.

Is it case sensitive? I just realise that I have Open, OPEN, oPEN, open, etc... the same goes for dont use.

Thank you.

Anonymous
Not applicable

Yes it's case sensitive. You can use the upper function to put your field in capital letters.

if(SubStringCount(upper(Name),'DONT USE')>0,'DONT USE',if(SubStringCount(upper(Name),'OPEN')>0,'OPEN',))

patriciousa
Creator II
Creator II
Author

It worked like a charm.

Thank you Anne.