Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Calculation problem in Counts

Hi Buddies,

Can u please help me out to calculate the count in straight table

For example:

if i do sum(total field) i'm getting total sum but i'm expecting sum by year wise. please help me out. Thanks in advance.

     

FiscalYearService Type            Field    count(total field)  Expectaion
FY13Type31323938
FY13Type42523938
FY14Type32923971
FY14Type44223971
FY15Type11239130
FY15Type25239130
FY15Type368239130
FY15Type456239130
1 Solution

Accepted Solutions
Anil_Babu_Samineni

May be this?

sum(aggr(sum(total <FiscalYear> Field),FiscalYear,ServiceType))

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)

View solution in original post

6 Replies
vinieme12
Champion III
Champion III

Count ( total <FiscalYear> field)

Sum ( total <FiscalYear> field)

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

May be this?

sum(aggr(sum(total <FiscalYear> Field),FiscalYear,ServiceType))

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Anonymous
Not applicable
Author

Hi Vineeth,

Thanks for reply, but its not working please check attached file

vinieme12
Champion III
Champion III

Use sum (total <FiscalYear> field)

On mobile , can't check the app sry

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

What is field here? Is it an existing expression in your straight table??

Then use

Sum (total <FiscalYear> Aggr (sum (Field),FiscalYear))

did you try the above, sivaprakash.t   , we only need to Aggr() on the dimension we need the total on.

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

try this:

1)Add Fiscal Year as Dimension.

2)Write expression be like:

   =Count(num( field))