Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Data comparision against time and one more dimension

Hi All,

I am new to qlikview . I have an requirement to show count of cases for current week and previous week against Priority of cases(P1,p2,p3).

I want the current week and previous week should come as an x-axis data and for each priority separate bars are required.

I have all the three dimensions in my data.

Case ID

Date from which I am calculating week

Priority as p1 p2 p3

I am not able to achieve a bar graph as per required manner. Can anyone please help me.

Thanks,

Rashmi

1 Reply
johnw
Champion III
Champion III

Here's one approach. See attached.

LOAD *
,if(Week=weekstart(today()) ,dual('This Week',Week)
,if(Week=weekstart(today(),-1),dual('Last Week',Week))) as ThisAndLastWeek
;
LOAD *
,weekstart(Date) as Week
;
LOAD
recno() as Case
,date(date#(20100601,'YYYYMMDD')+floor(rand()*32)) as Date
,'P'&ceil(rand()*3) as Priority
AUTOGENERATE 500
;

Dimension 1 = ThisAndLastWeek <- suppress when value is null
Dimension 2 = Priority
Expression = count(Case)