Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

Not applicable

Aggregating a sum to different dimensions

Hello to everybody! This forum has been a great help so far, but I have found a problem that I haven´t been able to solve using the current available knowledge. First of all, thank you for taking time going through my doubt.

What I am trying to achieve is the expression 1 in the image: to sum every count depending on Dim2 but ignoring Dim1, and using it as it is shown below. The count doesn´t appear like that, but comes from the count operation of different IDs

test.PNG

What I have reached so far, by using this expression =sum( aggr(count({<Dim1>}  distinct ID), Dim2)) throws this strange result:

test2.PNG

I hope someone can help, and that I will be able to help others in the near future

Kind regards

3 Replies
MVP
MVP

Re: Aggregating a sum to different dimensions

Try this

Count(TOTAL <Dim2> {<Dim1>} DISTINCT ID)

Not applicable

Re: Aggregating a sum to different dimensions

Thank you very much! It worked perfectly. I have one more question:

If we one to select the Dim1 from a list box in order to show only my desired ones, how could I achieve it? Through the formula used above, it always shows every Dim1, no matter whether it is selected.

Thank you very much so far Sunny!

MVP
MVP

Re: Aggregating a sum to different dimensions

That is because of the set analysis you had in your initial post.... try this

Count(TOTAL <Dim2> DISTINCT ID)