Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi ALL,
having problem for the if a word contains VD it will be "RCI" and the rest will be IMSPI
LOCATION | Expected Result |
VDD-1-1-2 | RCI |
VDD-1-3-2 | RCI |
LP121321312 | IMSPI |
i use this one for excel but in qliksens don't know the right expression
IF(ISNUMBER(SEARCH("VD",E1)),"RCI","IMSPI")
Hi, try
if(index([LOCATION], 'VD')>0, 'RCI', 'IMSPI')
its working now. thanks JustISO,
i also try adding in expression and it work also. because there is chance that location name they will add new.
if(index([LOCATION], 'VD')>0, 'RCI', if(index([LOCATION], 'CT')>0, 'RCI','IMSPI'))
in bigger scope of conditions, you can use other approach and use wildmatch() function, which allows to define in witch place of string to look needed symbols. In your case:
if( wildmatch([LOCATION], 'VD*', 'CT*')>0, 'RCI', 'IMSPI')
notice, that 'VD*' means that we are taking into account only cases when string starts with VD. '*VD*' would mean that we are looking 'VD' anywhere in the string.
Very Nice, i try it and its working.