Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
neena123
Partner - Creator
Partner - Creator

How do I create a bar chart that shows current month gross sales amount, orders shipped and last year same month gross sales amount and orders shipped?

I am trying to create a bar chart that shows current month gross sales amount, orders shipped and last year same month gross sales amount and orders shipped? Currently I am trying to achieve it by using this:

Gross Sales

This month:

Sum({$<[Ship Year]={$(=Year(today()))},[Ship Month]={$(=Month(today()))}>}[Gross Sales Amount])

Last Year same month:

Sum({$<[Ship Year]={$(=Year(today-1)))},[Ship Month]={$(=Month(today()))}>}[Gross Sales Amount])

Orders Shipped

(distinct if([Status]='Shipped',[Unique Order Key],null()))

The problem with those expressions is that it only lets me see the current status for February if I click on any other month the bar chart says "No Data To Display".  How do I fix this?

10 Replies
Not applicable

Use the max() function. Year(Max([Ship Year])) and Month(Max([Ship Month]))