4 Replies Latest reply: Jul 26, 2016 8:13 AM by Fernando Damas Wenzel

# Problem getting horizontal dimension for predetermined expressions

Hi folks,

I have this pivot table which i am trying to integrate in it some kind of labels for some expressions. For that, i am unsuccesfully trying to generate some horizontal dimensions, but i am getting trouble when determining what expressions should be down each label (or, in this case, dimension).

Here is the print of i am trying to achieve (here, Volume, Efetivo, Total Vs and FAT vs are not-so-well aligned text objects).

Is it possible to do?

I have not prepared any helping file, but if any of you guys need it, let me now and i'll get one done.

Thanks!

• ###### Re: Problem getting horizontal dimension for predetermined expressions

A sample would definitely help us understand what you are trying to do here.

• ###### Re: Problem getting horizontal dimension for predetermined expressions

Hi Sunny, thanks for your help.

Here is a sample, hope i could make myself clear over what i am trying to achieve.

Thanks again.

• ###### Re: Problem getting horizontal dimension for predetermined expressions

Looking to get this?

Script:

Inline:

LOAD * Inline [

Name, Sales, Country, Amount, Product

Fernando, 500, BR, 2

Ademir, 200, BR, 3

Claudio, 100, USA, 4

William, 300, ARG, 1

Fernando, 200, BR, 3

];

Dim1:

LOAD * Inline [

Dim1

1

2

];

Dim2:

LOAD * Inline [

Dim2

1

2

3

4

5

];

Dimension:

Name

=Pick(Dim1, 'General Numbers', 'KPIs')

=Pick(Dim2, 'Sales', 'Amount', 'Orders', 'Sales%', 'Sales per product')

Expression:

=If(Dim1 = 1,

Pick(Dim2, Sum(Sales), Sum(Amount), Count(Name)),

Pick(Dim2, Null(), Null(), Null(), Num(Sum(Sales)/Sum(TOTAL Sales), '##,%'), Sum(Sales)/Sum(Amount)))

• ###### Re: Problem getting horizontal dimension for predetermined expressions

Exactly what i was looking for.

Thanks a lot, Sunny!