Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Last Whole Week On Chart

Dear All,

I have two chart in my attached file. One of the chart shows some values for each week. And the other should show the latest whole week but there is something wrong in the file. For example today is 23rd of February I would like to present only last whole week (15-22 February interval) for the second chart. I want to see whole last week independently from the date selection. Would you please help me about it?

Hope to hear you soon.

Best Regards,

1 Solution

Accepted Solutions
Not applicable
Author

Hi Asim,

here a second try.

Good luck!

Rainer

View solution in original post

7 Replies
Not applicable
Author

Hi there,

took a look at your file but struggled with the Turkish (?) language... see if the below helps.

Not applicable
Author

Hi Lukas,

Thanks for your reply. But the result is not correct. You can cross check the result from the main chart. The values must be 180 , 142 ,142 for the last whole week. I made the correction by using below formula.Please check attached file. But I would like to learn using Set Analysis instead of above formula.

IF(Range='Last Week',Weekname(TARIHCQ))




Not applicable
Author

Hi,

gotcha - you had for the dimension week-1.

I've removed the -1 and it works. Basically it IS using set analysis:


=sum({1}
if(inweek(TARIHCQ,WeekStart(Today(2)),-1),YI_SAYI)
)

The {1} means it's applying the expression on the whole data set, regardless of the current selection. Give it a try - select any date and the chart will still show the latest week's data only.



Not applicable
Author

Hi Asim,

see the attached example for an SET ANALYSIS example.

Without selection: Graph shows the week before the actual week.

With selection: Week before selected week.

You can play around with it to become familiar with set Analysis.

Good luck!

Rainer

Not applicable
Author

Hi Rainer,

Thanks for your reply. But this is not the solution for me. I want to be static view after reloading. For example when I reload the document it is required to show the value for week before the actual week. It must not effected with the selection of date.

Best Regards,

Not applicable
Author

Hi Asim,

here a second try.

Good luck!

Rainer

Not applicable
Author

Hi Rainer,

seems that I'm facing the same problem that Asim had a while ago. Unfortunately I'm still using the QVPE and can't open your attached file. Would you mind posting the set analysis formula? I want to show all order that were generated in the previous week - but only the previous week.

I tried to use this one but I did not work out they way I wanted ;-))

Sum({< Status = {'Offener Auftrag'}, [Erstellungsdatum] = {'>=$(=Week(Today() -1, 'DD.MM.YYYY'))'} >} [Auftragsmenge in Tonnen])

Thanks for your help and best regards
Günter