# Qlik DataMarket Discussions

Discussion Board for collaboration regarding Qlik DataMarket.

New Contributor II

I want structure like below:

Expression1  Expression2          Expression 3  Expression 4  Expression 5

Can this be achieved with pivot table? If yes kindly give detailed procedure with what expressions need to be used

1 Solution

Accepted Solutions
New Contributor III

[

H1, H2

]

;

Detail:

[

Number,Expression 1,Expression 2,Expression 3,Expression 4,Expression 5

'1','1','2','3','4','5'

'2','11','12','13','14','15'

'3','21','22','23','24','25'

]

;

Measure:

If(H2 = 'Expression 1', ([Expression 1]),

If(H2 = 'Expression 2', ([Expression 2]),

If(H2 = 'Expression 3', ([Expression 3]),

If(H2 = 'Expression 4', ([Expression 4]),

If(H2 = 'Expression 5', ([Expression 5])

)))))

7 Replies
New Contributor III

[

H1, H2

]

;

New Contributor II

My query is still not solved as the header name is repeating for every set of measures. I want to apply headers on measures selectively.

Valued Contributor II

HI Neha,

Like Below:

INLINEDATA:

];

Thanks,

Arvind Patil

New Contributor III

[

H1, H2

]

;

Detail:

[

Number,Expression 1,Expression 2,Expression 3,Expression 4,Expression 5

'1','1','2','3','4','5'

'2','11','12','13','14','15'

'3','21','22','23','24','25'

]

;

Measure:

If(H2 = 'Expression 1', ([Expression 1]),

If(H2 = 'Expression 2', ([Expression 2]),

If(H2 = 'Expression 3', ([Expression 3]),

If(H2 = 'Expression 4', ([Expression 4]),

If(H2 = 'Expression 5', ([Expression 5])

)))))

New Contributor II

Hi thanks Chris I am able to segregate the measures but am facing some limitations. Can you tell how to limit the value of a number while applying the condition.

for example,

My expression is sum(revenue), I want the number to be limited to 2 decimal value whereas in other expression I want a whole number

New Contributor III

Integer

=Num('123.45','###0') = 123

2 decimals

=Num('123.45','0.00') = 123.45

= Num(Sum([revenue]),'0.00')

New Contributor II

Thanks Chris , It worked.

I have one more question kindly help me out

I want to add Text Color Expression

After first and second selection there should be no change in text color

and after third selection from filter pane, colors should change as per the comparison between first and second selection.

I am using this expression:-

if (count({\$}empid) > count({\$1}empid) , Red() , Green() )