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: 
cbaqir
Specialist II
Specialist II

Date Dimension Aggr(max)) Repeating

I thought I had figured out the syntax for my date dimension because it looks right when one DEFECT_ID is selected but when multiple are selected, the date is repeating instead of showing aggregated by month. Can someone please help?

=aggr(max( date(DEFECT_STATUS_START_DATE,'MMM-YYYY')),DEFECT_ID)

2018-09-17_7-50-20.jpg

1 Solution

Accepted Solutions
stigchel
Partner - Master
Partner - Master

Dimension

=aggr(max( date(Monthstart(DEFECT_STATUS_START_DATE),'MMM-YYYY')),DEFECT_ID)

ScrAggrMonthstart.png

View solution in original post

6 Replies
stigchel
Partner - Master
Partner - Master

The function

date(DEFECT_STATUS_START_DATE,'MMM-YYYY')

Only formats the date. The date is a dual where the number part will still reflect each individual date. To have a single date per month you can use MonthStart(Date.....

stigchel
Partner - Master
Partner - Master

cbaqir
Specialist II
Specialist II
Author

Is there a way to show MonthStart as MMM-YYYY?

stigchel
Partner - Master
Partner - Master

Sure, should have turned that around myself already, so just wrap the formatting date function around the monthstart function instead of the other way around

YoussefBelloum
Champion
Champion

Hi,

I think this calculated dimension will help get the expected output

=Month(DEFECT_STATUS_START_DATE)&Year(DEFECT_STATUS_START_DATE)


stigchel
Partner - Master
Partner - Master

Dimension

=aggr(max( date(Monthstart(DEFECT_STATUS_START_DATE),'MMM-YYYY')),DEFECT_ID)

ScrAggrMonthstart.png