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

How to put a expression as Dimension on Pivot Table

Hello Community,

I have a formula that's is very similar to the following:

=if(Dimensionality()=0,
sum(aggr(
sum(DISTINCT aggr(NODISTINCT sum(Field1),Field5,Field6))
/
sum(DISTINCT aggr(NODISTINCT sum(Field2),Field5,Field6))
*
(
sum(DISTINCT aggr(NODISTINCT sum(Field2),Field5,Field6))
/
sum(DISTINCT aggr(NODISTINCT sum(Field2),Field5,Field7))
)
,Field5,Field6)),

if(Dimensionality()=1,
sum(aggr(
sum(DISTINCT aggr(NODISTINCT sum(Field1),Field5,Field8,Field6))
/
sum(DISTINCT aggr(NODISTINCT sum(Field2),Field5,Field8,Field6))
*
(
sum(DISTINCT aggr(NODISTINCT sum(Field2),Field5,Field8,BasicUoMCode))
/
sum(DISTINCT aggr(NODISTINCT sum(Field2),Field5,Field8))
)
,Field5,Field8,Field6))
... and so on

Since Field 5 is a YearMonth field. And the result is the same in 12 months i only want have 1 column in Pivot Table. If i had this  expression it appears in all yearmonth columns, but i only want to see it 1 time and changing accordingly my dimensionality.

Anyone can help?

Best regards

Bruno Paulo

1 Reply
Anil_Babu_Samineni

Image please?
Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)