Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

Not applicable

summing across mulitple variables

I have a table that has the following columns:

DateIDCount%
5/3315x
5/33210y
5/43110z
5/43215u

I would like to sum the Count column for each combination of Date and ID so I can see the % of that day and ID that set makes up.

I want:

x = 5 / (5 + 10) = 33.33%

y = 10 / (5 + 10) = 66.66%

z = 10 / (10 + 15) = 40%

u = 15 / (10 + 15) = 60%

How do I set up the % column to do this?

Tags (3)
1 Solution

Accepted Solutions

summing across mulitple variables

Hi,

     Check with this

     sum(Counts)/sum(Total<Date> Counts)

Celambarasan

5 Replies
Not applicable

summing across mulitple variables

Try using

sum(total Aggr(count(field),Date))

Not applicable

summing across mulitple variables

I tried using the following:

sum(Counts)/sum(Aggr(sum(Counts),Date,ID))

This worked, but it only gave a % for the largest Count for each Date.

So in my example above:

x is NULL

y = 66.66%

z is NULL

u = 60%

How can I get the % to work for all rows?

Not applicable

Re: summing across mulitple variables

What is the result of the expression:

Aggr(sum(Total Counts),Date)

summing across mulitple variables

Hi,

     Check with this

     sum(Counts)/sum(Total<Date> Counts)

Celambarasan

Not applicable

summing across mulitple variables

For the example I gave, sum(Counts)/sum(Total <Date> Counts) worked

When I added another variable to the mix I then wanted to use:

sum(Counts)/sum(Total <Date,ID> Counts)

which allowed me to sum across Date and ID and Disposition

Community Browser