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: 
Anonymous
Not applicable

Monthly Bar Chart for weekly updated incremental table

Hi Everyone,

I have a problem with building a bar chart.

In my system the table is updated weekly on the status of every row in the table - I am kind of creating a screen shot of a table for that particular week. I need to create a bar chart that shows monthly values of Sales. the date of the data load is stored in a field called _loadedOn.

My current approach:

Dimension: MonthName(_loadedOn)

Measure: Sum(Sales)

     The problem with this approach is that it sums up all the weeks within a month and gives a huge value. What is preferable instead is summing only the latest week in a month.

Any ideas on how to tackle this?

Thanks.

Edil

9 Replies
ahaahaaha
Partner - Master
Partner - Master

Hi Edil,

I think you should use the Master calendar.

Regards,

Andrey

vinieme12
Champion III
Champion III

You should be referring to the max(Loadedon) date in Set analysis

sum({<LoadedOn = {"=Date(Max(LoadedOn))"}>}Sales)

Dates in Set Analysis

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
Anonymous
Not applicable
Author

I started with $<_loadedOn={"$(=Date(Max(loadedOn)))"}> inside the set expression, however the problem there is that it disregards the dimensions of months. Meaning that it only shows me the last month and all the previous months are disregarded. In the case I need, we need to choose a max date in every month.

and yeah, thanks for your time!

Anonymous
Not applicable
Author

Thanks Andrey,

Want to stick to my current fields available before jumping to creating extra ones.

vinieme12
Champion III
Champion III

please post a sample app

Preparing examples for Upload - Reduction and Data Scrambling

or try

sum(AGGR( sum({<LoadedOn = {"=Date(Max(LoadedOn))"}>}Sales) , Month))

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
beck_bakytbek
Master
Master

beck_bakytbek
Master
Master

Anonymous
Not applicable
Author

Rahmat, Bek

May be I will have to look at something like this:

https://community.qlik.com/thread/74202

beck_bakytbek
Master
Master

HI Edil,

look at this: https://www.youtube.com/watch?v=ckb57Mjrheg

it is about : creating of flags

i hope that helps

Beck