Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
soniasweety
Master
Master

always last 6 months

Hi All,

I have an requirement like...

I have data for all years    so  I want to display   by default  max year selected   and

if I select any year and any month    the straight table should display previous 6months of selected month.

attached sample  and excel data

9 Replies
sunny_talwar

You want this in straight table only? Or can we use Pivot table?

soniasweety
Master
Master
Author

anything is fine sunny

Anil_Babu_Samineni

How about this?

Sum({<MonthNo = {">=$(=Max(MonthNo-6)) <=$(=Max(MonthNo))"}>} Sales)

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
sunny_talwar

Check attached may be

soniasweety
Master
Master
Author

here one more thing  I need to every month .....not totals each month  product category wise I need to show.

soniasweety
Master
Master
Author

like below image  I need to display last six month by  product category wise.mnths.JPG

soniasweety
Master
Master
Author

yes sunny ... but here when I open the application  max year should be by default  it is not showing any default value

and

can you explain the logic how its working ...if you don't mind..!!!!!!!1

Anil_Babu_Samineni

Seems working

Capture.JPG

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Anil_Babu_Samineni

You need to assign trigger. OnOpen - Actions - Select in field - Year - Search string (=Max(Year))

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful