Skip to main content

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Skip the ticket, Chat with Qlik Support instead for instant assistance.
Showing results for 
Search instead for 
Did you mean: 
Contributor III
Contributor III

sum with Total and dimensionality

Hi guys,

I have a variable that returns the dimensionality and the respective Dimension, and I need to include this in the set analysis measure.

variable1 ( return dimensionality:

If(Dimensionality() = 1,'DIMENSION_1',


sum(Total < $(variable1), [Fiscal Year] > {<[FLAG]={1}>} Value)

But I get the error:

Error in expression: '>' expected

sum(Total < If(Dimensionality() = 1,'DIMENSION_1',if(Dimensionality()=2,'DIMENSION_2')), [Fiscal Year] > {<[FLAG]={1}>} Value)

expected variable1 result

sum(Total < 'DIMENSION_1', [Fiscal Year] > {<[FLAG]={1}>} Value)


sum(Total < DIMENSION_2', [Fiscal Year] > {<[FLAG]={1}>} Value)

depends of dimensionality rows number



How can I solve this?

I tried 

sum(Total < $(=$=(variable1)), [Fiscal Year] > {<[FLAG]={1}>} Value)

sum(Total < $=(variable1), [Fiscal Year] > {<[FLAG]={1}>} Value)

I think the problem is in the evaluate variable1, but I am not getting the correct result.

Labels (5)
1 Reply
Champion III
Champion III

Try below, to evaluate string returned as a field

=sum(Total < $(=$(variable1)), [Fiscal Year] > {<[FLAG]={1}>} Value)



Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.