Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Read about Qlik’s Response to COVID-19 Read the Letter, Join the Group.
Highlighted
New Contributor III

How to get monthly average sales per product?

Hi everyone,

I'm creating a chart which displays the monthly average sales per product however I have a daily data set in Excel.

1.PNG

In the Expressions tab, I used this expression: =Avg(Aggr(Sum(Sales),Date,Product)) and upon applying, chart looked like this

2.PNG

The scale was a lot smaller since I have data set in daily format but what I need is the monthly averages.

I've also tried editing the Script using the MonthStart string to no avail. Hope someone can help me on this.

Thanks!

Tags (2)
1 Solution

Accepted Solutions
Highlighted

Re: How to get monthly average sales per product?

Have you tried this?

=Avg(Aggr(Sum(Sales),MonthYear,Product))

Where MonthYear is calculated in the script like this

Date(MonthStart(Date), 'MMM-YYYY') as MonthYear

View solution in original post

2 Replies
Highlighted

Re: How to get monthly average sales per product?

Have you tried this?

=Avg(Aggr(Sum(Sales),MonthYear,Product))

Where MonthYear is calculated in the script like this

Date(MonthStart(Date), 'MMM-YYYY') as MonthYear

View solution in original post

Highlighted
New Contributor III

Re: How to get monthly average sales per product?

I did it! Thanks for the help!