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: 
Ronald
Contributor III
Contributor III

Group rows in chart

Hi, I need group in Qtrs, for example:

M24 + M23 + M22 AS QTR0 

M23 + M22 + M21 AS QTR-1

M22 + M21 + M20  AS QTR-2

 

Table1

QRQTR.png

 

Labels (1)
5 Replies
msKarthikeyan
Employee
Employee

Hi,

The best option  is to create a new column for quarter in the load script.

If you want to include in chart, you can try something like this.

but this will be not update dynamically as more data as added.

=if(Match(month,'m1','m2','m3'),'Q1',if(Match(month,'m4','m5','m6'),'Q2','Q3'))

-Karthik 

BlueMap
Contributor
Contributor

Visit: www.bluemap.co
BlueMap specialises in providing training and services for the IT community.
Ronald
Contributor III
Contributor III
Author

Q1: m1,m2,m3

Q2:m2,m3,m4

Ronald
Contributor III
Contributor III
Author

if(Match(month,'m1','m2','m3'),'Q1',if(Match(month,'m2','m3','m4'),'Q2','Q3'))

But Q2 result is incorrect, because don´t sum m2+m3+m4, only show m4 value

Ronald
Contributor III
Contributor III
Author

In Measure I have:

Sum({<Origen={'Market'}>} Aggr(Sales,Period,Date,Sales))