Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
BARC’s The BI Survey 19 makes it official. BI users love Qlik. GET REPORT
milad-saeedi
New Contributor

Hiding past hours from last week in comparison to same day in last week chart

Hi,

I have a chart that compares my current status to the same day last week (-7d).

but my problem is the data that shows in the chart, as you can see I have data for upcoming hours from last week but I need to show them when it's time arrives  not before them:

Annotation 2019-07-30 104037.png

4 Replies
Partner
Partner

Re: Hiding past hours from last week in comparison to same day in last week chart

Hi!

In your "7 days ago" expression add set analysis, something like:

Sum(   {<HourDim={"<=$(=Max(HourDim))"}>}   Value)

Partner
Partner

Re: Hiding past hours from last week in comparison to same day in last week chart

Hi,

You can achieve this by adding NOW() function in set analysis.

You Know What To Do.
milad-saeedi
New Contributor

Re: Hiding past hours from last week in comparison to same day in last week chart

Hi,

 

Thanks for your kind reply,

could you please edit my expression as you think it's true?

=Count({<CreateDate={">=$(=daystart(today()-7))<=$(=dayend(today()-7))"}>} ID)

Partner
Partner

Re: Hiding past hours from last week in comparison to same day in last week chart

Hi!

You have to have native dimension with cyclic numeric hours (0, 1, 2... 23). And CreateDate dimension must be Timestamp. Depending on what you want to limit: max hour based on loaded records or current time, you can use Now() or Max(CreateDate). Your expr looks like like:

=Count({<

CreateDate={">=$(=daystart(today()-7))<=$(=dayend(today()-7))"},

HoursDim={"<=$(=Hour(Max(CreateDate)))"} 

// OR HoursDim={"<=$(=Hour(Now()))"}      

>} ID)