Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

williamfuu
Contributor II

Filtering a certain Day number in Set analysis

Any ideas why the following expression doesn't work?

Sum({$<LLR.PdCorrente-={'100'}, Day(DtRef)={1}>} Saldo)

I want the measure to only sum the values for the first day of each month.

1 Solution

Accepted Solutions
MVP
MVP

Re: Filtering a certain Day number in Set analysis

Try this

Sum({$<LLR.PdCorrente-={'100'}, DtRef = {"=Day(DtRef) =1"}>} Saldo)

4 Replies
MVP
MVP

Re: Filtering a certain Day number in Set analysis

Create a new field in the script and use the field name in set analysis

Day(DtRef) as DayRef

and then this

Sum({$<LLR.PdCorrente-={'100'}, DayRef={1}>} Saldo)

williamfuu
Contributor II

Re: Filtering a certain Day number in Set analysis

Thanks for the quick response.

Anyway to achieve this without messing with the script?

I'm currently working with just the auto-generated script, and I'm not quite comfortable to press the "Unlock" button yet.

Also, why doesn't the auto calendar create a day field?

MVP
MVP

Re: Filtering a certain Day number in Set analysis

Try this

Sum({$<LLR.PdCorrente-={'100'}, DtRef = {"=Day(DtRef) =1"}>} Saldo)

williamfuu
Contributor II

Re: Filtering a certain Day number in Set analysis

Perfect, thank you!