Qlik Community

App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Announcements
Don't miss the upcoming Q&A with Qlik session on Qlik Application Automation on November 16th! REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
jsobrinho
Creator
Creator

Fact by month and Fact by day

Hi guys,

I have a table with consolidated values by months and I have another table with consolidated values by day. I need to use this information in a bar chart, so when the user clicks on the bar of the month I need to show data for the day. How can I use these two pieces of information?

Values consolidate by month, show that in Feb my balance until Feb is 60, and the balance change for another month until May, with a total balance = 100

Month:
LOAD * INLINE [
Date Month, Values
01/01/2020, 50
01/02/2020, 60
01/03/2020, 30
01/04/2020, 10
01/05/2020, 100
];

 

Values consolidate by day, it's the same logic, I have my balance by day, so I can't sum all days, because each day has the balance until that date.

Day:
LOAD * INLINE [
Date day, Values
01/01/2020, 10
02/01/2020, 10
03/01/2020, 10
04/01/2020, 50
05/01/2020, 20
06/01/2020, 5
07/01/2020, 1
08/01/2020, 60
09/01/2020, 50
03/02/2020, 80
04/02/2020, 70
17/02/2020, 15
19/02/2020, 60
];

Fact month Fact day.png

In this case, Jan and Month view, I need to show only 50, and when I selected the day view, I need to show all values by day.

Labels (2)
1 Reply
Quy_Nguyen
Specialist
Specialist

Hi,

You just need your daily data, then use this expression as your measure: FirstSortedValue(Values,-[Date day])

Dimension: Month([Date day]) or [Date day] or a drill-down dimension Month-Date day is better.