Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Searching other codes in script

Hi,

I have the following script showing in my load script.

LOGINFO:

LOAD *, [logdate] as Logdate_Month,

  Year([logdate]) as Logdate_Year

  ,num(today()) - 1460 as test123

  ,num([logdate]) as logdatetest

  , if(MID(fixcode,11,4)='RCL0','Oracle'

  , if(MID(fixcode,11,4)='RRCL','Oracle'

  , if(MID(fixcode,11,4)='0000','Bottomline'

  , if(MID(fixcode,11,4)='FRMS','Bottomline'

  , if(MID(fixcode,11,4)='C000','Call Media'

  , if(MID(fixcode,11,4)='CLLM','Call Media'

  , if(MID(fixcode,11,4)='CSCD','Cascade'

  , if(MID(fixcode,11,4)='CSC9','Cascade'

  , if(MID(fixcode,11,4)='CST6','Castelle'

  , if(MID(fixcode,11,4)='CM02','Client Manager'

  , if(MID(fixcode,11,4)='CGNS','Cognos'

  , if(MID(fixcode,11,4)='CYBR','Cyborg'

  , if(MID(fixcode,11,4)='RCYB','Cyborg'

  , if(MID(fixcode,11,4)='DSCV','Discoverer'

  , if(MID(fixcode,11,4)='HXGN','Hexagon'

  , if(MID(fixcode,11,4)='HSBC','HSBC Net'

  , if(MID(fixcode,11,4)='FS00','IFS'

  , if(MID(fixcode,11,4)='FS20','IFS'

  , if(MID(fixcode,11,4)='MO04','Maximo'

  , if(MID(fixcode,11,4)='MA03','Maximo'

  , if(MID(fixcode,11,4)='MDS1','Midas'

  , if(MID(fixcode,11,4)='MDS0','Midas'

  , if(MID(fixcode,11,4)='QLK1','Qlikview'

  , if(MID(fixcode,11,4)='QLKW','Qlikview'

  , if(MID(fixcode,11,4)='RC50','Reports'

  , if(MID(fixcode,11,4)='SVRN','Severn Trent'

  , if(MID(fixcode,11,4)='STRT','Streetworks'

  , if(MID(fixcode,11,4)='STRM','Strumap'

  , if(MID(fixcode,11,4)='S006','Syclo'

  , if(MID(fixcode,11,4)='S008','Syclo'

  , if(MID(fixcode,11,4)='VRSN','Version One'

  , if(MID(fixcode,11,4)='VRS1','Version One'

  , if(MID(fixcode,11,4)='MPCT','WaterXP'

  , if(MID(fixcode,11,4)='ERXP','WaterXP'   

  )))))))))))))))))))))))))))))))))) AS SOFTWARE_TEST

  where num(today()) - 1460 < [logdate];

As you can see I have quite alot of if statements that look at a specific code and then enter it as a specific software value. 

However there may be some code that are no in the above list, however I want to show them as other.  Can this be done.

1 Solution

Accepted Solutions
Not applicable
Author

Hi Jonathan,

behind last 'WaterXP' word add following:  ,'Other value' .

regards

View solution in original post

2 Replies
Not applicable
Author

Hi Jonathan,

behind last 'WaterXP' word add following:  ,'Other value' .

regards

whiteline
Master II
Master II

Hi.

It's cool

Try applymap() instead.