Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

lakwinder
Contributor III

Why isn't this where MATCH working? In load script

Hi Guys

Why isn't this where MATCH working? in load script

Many thanks in advance

sum(if(WHERE match  ([PRODUCT],'xxx','yyy','zzzz'),Value)) AS NEWTEST,

15 Replies
MVP
MVP

Re: Why isn't this where MATCH working? In load script

Try it without WHERE

Sum(If(Match(PRODUCT, 'xxx', 'yyy', 'zzzz'), Value)) as NEWTEST


UPDATE: You might need a Group By statement in case you have other fields in this particular load.

balrajahlawat
Esteemed Contributor

Re: Why isn't this where MATCH working? In load script

Wow, where clause in IF condition....

Your syntax is wrong, try what Sunny suggested you

lakwinder
Contributor III

Re: Why isn't this where MATCH working? In load script

It still doesn't work, it says Invalid expression

lakwinder
Contributor III

Re: Why isn't this where MATCH working? In load script

It still doesn't work, it says Invalid expression

lakwinder
Contributor III

Re: Why isn't this where MATCH working? In load script

I've got the GROUP BY

Thanks

MVP
MVP

Re: Why isn't this where MATCH working? In load script

Can you share your script for where you are trying this out?

lakwinder
Contributor III

Re: Why isn't this where MATCH working? In load script

Sorry guys, i had one extra field that wasn't on the GROUP BY

Sorry for being a pain, ill award you guys points

lakwinder
Contributor III

Re: Why isn't this where MATCH working? In load script

Where's the option to mark your request as correct?

balrajahlawat
Esteemed Contributor

Re: Why isn't this where MATCH working? In load script

FYI....If you are using aggregate function at script level then you should Group by.....

Expression suggested by Sunny was right, the only issue was that you did not share the the full script code with Group By

Community Browser