Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
sersal10
Creator
Creator

how to make 2 measures share MonthDay dimension

Hi all. 

I have sales data for event tickets from April last year and this year. Is there a way to put them in the same chart and have them overlaid? I tried to load the sold_date field as MonthDay creating that new filed so I could use it as the shared dimension. 

But I see that they can't share it for some reason. I think it links it to the date somehow. For instance I have 2 diferent 03-10 one for last year and another for this year at the right side of the line chart. Is there a way to make them share it? 

The expressions I have for both measures as I need it to be the accumulated sales, are these:

For last year:

=Rangesum(Above(Sum({<year_event=, month_event=, event_code=p(previous_event_code), event_to_compare=, event_name= >} [quantity]), 0, RowNo()))

For this year:

RangeSum(Above(Sum(quantity), 0, RowNo()))

 

When I load the date the code is:

Date(Floor(sold_date), 'MM-DD') as MonthDay,

 

And this is the chart now. Notice that after last year MonthDay, follows the beginning of this year:

 

Captura de pantalla 2024-04-30 a las 16.07.58.png

Any help appreciated!!!

Labels (5)
1 Reply
dmac1971
Creator III
Creator III

Do you have a master calendar in your report?  If not you should read up on them, and add one in.  Good luck.