Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
Make your voice heard! Participate in the 2020 Wisdom of Crowds® Survey. BEGIN SURVEY
Highlighted
max_potass
Contributor

Set Value of Expression to Zero if Dimension has one Value

Hello everyone,

I have a small Problem I can't find anything about in the Documentation or here...

I want to create a Pivot Chart with 2 Dimensions and 2 Expressions.

One of the Expressions only has Values for the first Dimension. So Qlikview is "pasting" these values for the second Dimension.

I want these values in the second Dimension to be zero.

I guess I need an "If" and a functions that tells me, if the current 2nd Dimension has one specific value. But GetSelectedCoumt does obviously not work, as it is not an selection. I need something similar which works here, right?

Does anyone has an Idea, how to fix this?

I have:

I have.png

I want:

I want.png

Best regards

Max

Tags (2)
1 Solution

Accepted Solutions
Highlighted
MVP & Luminary
MVP & Luminary

Re: Set Value of Expression to Zero if Dimension has one Value

You could catch this with a query on the dimensionality maybe like:

if(dimensionality() = 1, Expression2)

- Marcus

View solution in original post

3 Replies
Highlighted
MVP & Luminary
MVP & Luminary

Re: Set Value of Expression to Zero if Dimension has one Value

You could catch this with a query on the dimensionality maybe like:

if(dimensionality() = 1, Expression2)

- Marcus

View solution in original post

Highlighted
sergio0592
Valued Contributor II

Re: Set Value of Expression to Zero if Dimension has one Value

Hi, try with :

=if(RowNo()=1,Expression2)

Highlighted
max_potass
Contributor

Re: Set Value of Expression to Zero if Dimension has one Value

Thank you! That worked.