Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

hopkinsc
Valued Contributor II

Help with expression

Hi everyone,

Can you tell me if the following expression is correct please?

sum(if(wildmatch(Narrative,'STKADJ*'>0 or Narrative,'GRN*')>0,StockValue))

I need it to give me a figure of the StockValue for anything where the Narrative is wildmatched to STKADJ and GRN.

Thanks

1 Solution

Accepted Solutions
MVP
MVP

Help with expression

If I understood correctly:

=sum(if(wildmatch(Narrative,'STKADJ*','GRN*')>0,StockValue))

3 Replies

Re: Help with expression

Hi,

     Change it to

     sum(if(wildmatch(Narrative,'STKADJ*') or wildMatch( Narrative,'GRN*'),Sum(StockValue)))

Celambarasan

MVP
MVP

Help with expression

If I understood correctly:

=sum(if(wildmatch(Narrative,'STKADJ*','GRN*')>0,StockValue))

hopkinsc
Valued Contributor II

Help with expression

Thanks for that. It didn't quite work but i changed it to

sum(if(wildmatch(Narrative,'STKADJ*') or wildMatch( Narrative,'GRN*'),StockValue))

Which worked.

Thanks

Hi Stefan,

Thanks that also worked and is easier to understand.

Thanks