Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear All,
I am trying to do script calculation in Qlik Sense. I am trying to find if Fields contains & does not contains particular word in a field.
Eg
Field_name
Hyd
Hyd
Hyd,Sec,Hyd-Sec
E-Hyd,Sec
E-Hyd,Old
Sec,Hyd
count(if(field contains "Hyd"and not contains "E-Hyd",1,0) as Countvalue
So I should get a output value = 4 (which contains Hyd but not E-Hyd)
Like this:
Sum(If(WildMatch(field, '*Hyd*') > 0 And Wildmatch(field, '*E-Hyd*') = 0, 1, 0)) as Countvalue
Like this:
Sum(If(WildMatch(field, '*Hyd*') > 0 And Wildmatch(field, '*E-Hyd*') = 0, 1, 0)) as Countvalue
Hi Dinesh,
Try using WildMatch.
Count(if(not match(Field_name,'E-Hyd'),Field_name))
try using to create a kpi in UI.
Please let me know if u have any questions.
Thanks 🙂