Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
reivax31
Partner - Creator III
Partner - Creator III

Show all dimensions value at any time with calendar

Hi Qliker,

I have a little issue with my chart display. I used a canonical calendar to put 2 date dimensions on x-axis. If I have no selection then everything is displayed perfectly because each week is displayed in my chart:

NoSelection.png

But then if I make a selection on my DS_Number (it's like my ID number) the week in my calendar where there are no related data are removed from my chart (even selecting all my DS_Number😞

WithSelection.png

Should I change the way the canonical Calendar works or is there another trick to make my chart display everything? I already trying show null value in dimension and also display Zero for measure...

QVF file is attached for better understanding.

Thanks for your support

1 Solution

Accepted Solutions
sunny_talwar

May be try this

If(Only({1} CanonicalWeek) <= 38, RangeSum(Above(Count({$<DateType={'Target'}>} DS_Number), 0, RowNo())) + Avg({1} 0))

View solution in original post

4 Replies
sunny_talwar

Try by adding this to your expression

Count(if(DateType='Forecast', DS_Number)) + Avg({1} 0)

reivax31
Partner - Creator III
Partner - Creator III
Author

Hi Sunny,

Your solution worked perfect for a normal count as I showed in my initial exemple. But then I whanted to apply this same technique to accumalation.

Test 1: rangesum( above( Count({$<DateType={'Target'}>} DS_Number),0,rowno()))+ Avg({1} 0)

This also worked perfectly when I added a  "if" condition:

Test 2: IF(CanonicalWeek <= 38,rangesum( above( Count({$<DateType={'Target'}>} DS_Number),0,rowno()))+ Avg({1} 0))

Result:

ResultNoFilter.png

But then if a set filter WP=CWB I have some gaps in my chart for measure that has the "IF" condition:

ResultWithFilter.png

I tried a few things but nothing helped... I changed QVF in original post to show this new case.

sunny_talwar

May be try this

If(Only({1} CanonicalWeek) <= 38, RangeSum(Above(Count({$<DateType={'Target'}>} DS_Number), 0, RowNo())) + Avg({1} 0))

reivax31
Partner - Creator III
Partner - Creator III
Author

Perfect it solved my problem. I don't understand why but I will keep this syntaxe in my little "help list"