Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
ramanannad
Contributor III
Contributor III

Pivot grouping

Dear Experts,

I have the simple file below loaded :

tmp:

LOAD

    Group,                                                  --consists of group 1, group 2, group 3

    Month,                                                  --consists of JAN, FEB, MAR

    count(Customers)

FROM [lib://Data Source/somefile.csv]

(txt, utf8, embedded labels, delimiter is ',', msq) ;

My expected output is as such in a pivot table :

sample pivot.png

It shows the count of customers that changes group over the months, been trying for days to achieve this. No luck yet

Please help 🙂

Thanks

Ram

Malaysia

5 Replies
qlikview979
Specialist
Specialist

Hi Ramanan,

Please attached your source file.

Regards,

Mahesh.

Anonymous
Not applicable

Hi Ramanan:

Use this expression.

=MaxString(Aggr(Only(Group),CountCust,Month))

Snap.PNG

Anil_Babu_Samineni

Manuel,

Is there any chance to share that qvw for reference

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Anonymous
Not applicable

Yes, there you have.

Thanks!!

ramanannad
Contributor III
Contributor III
Author

Great share Manuel, Thanks

But am afraid that I missed out an important detail in my previous explanations, the data is actually granular down to the individual customerID rather than a count of customers, with this granular level table, how do we achieve the mentioned pivot table? Kindly help

tmp:

LOAD

    Group,                                                  --consists of group 1, group 2, group 3

    Month,                                                  --consists of JAN, FEB, MAR

    count(CustomerID)

FROM [lib://Data Source/somefile.csv]

(txt, utf8, embedded labels, delimiter is ',', msq) ;

sample pivot.png