Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
ALERT: QlikView server communication interruptions following Microsoft Windows Domain Controller security updates
cancel
Showing results for 
Search instead for 
Did you mean: 
dhanu_today
Creator
Creator

Average wise bucket


Hi Everyone ,

I have the fields like direction,ID,SAL.I have calculated the average by sum(sal)/Count(Total ID)

After getting above result i have to show the ID's count bucket wise based on the average calculated above.

DIRECTIONAverage(i.e. sum(sal)/count(Total ID)Count(ID)SAL<=0SAL>0 AND SAL<=10000SAL>10000 AND SAL<=20000SAL>20000 AND SAL<=50000SAL>=50000 AND SAL<=100000SAL>=100000
S8993.17715 1
N18901.05612111
E138141971312
W10128503.044 112

Here am attaching the sample data as well.

Thanks in adv,

Dhanu

Labels (1)
12 Replies
MK_QSL
MVP
MVP

what is the difference between these two?

Count-Bucket wise format

dhanu_today
Creator
Creator
Author

Thanks Manish For qucik response.But in this criteria I have to get the above mentioned format based on the average

value  for their ID's. But in the earlier one we directly created the bucket based on the sum(sal) with respect their ID's

I hope you got the logic.

Thanks,

Dhanu

MK_QSL
MVP
MVP

You mean to say instead of

COUNT of ID where Sal <=0

you need

COUNT of ID where SUM(Sal)/Count(TOTAL ID) <=0

dhanu_today
Creator
Creator
Author

Correct Manish....I have to show the ID's count based on the average value.

Dhanu

MK_QSL
MVP
MVP

Are you sure you have given correct output in OUTPUT FORMAT worksheet?

Check below...

SAL<=0
1
1
1
DIRECTIONAverage(i.e. sum(sal)/count(Total ID)Count(ID)SAL<=0
S8993.1771
N18901.0561
E138141971
W10128503.044
vikasmahajan

You can use calculated Dimensions using following expression for buckets

=if((num(vDateForAgeing)-[Due Date CLE])<=0 ,'Not Due',

if(IsNull([Due Date CLE]) OR [Due Date CLE]='','Not Due',

if((num(vDateForAgeing)-[Due Date CLE])>=1 and (num(vDateForAgeing)-[Due Date CLE])<=30,'1-30',

if((num(vDateForAgeing)-[Due Date CLE])>=31 and (num(vDateForAgeing)-[Due Date CLE])<=60,'31-60',

if((num(vDateForAgeing)-[Due Date CLE])>=61 and (num(vDateForAgeing)-[Due Date CLE])<=90,'61-90',

if( (num(vDateForAgeing)-[Due Date CLE])>=91 and (num(vDateForAgeing)-[Due Date CLE])<=180,'91-180',

if( (num(vDateForAgeing)-[Due Date CLE])>=181,'Above 181',

0)))))))

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.
dhanu_today
Creator
Creator
Author


Its My typo....instead of SAL i have to take Based on this SUM(Sal)/Count(TOTAL ID) <=0 etc.... i have to show the format above.

Thanks,

Dhanu

MK_QSL
MVP
MVP

My question is how you get <= 0 for S, N and E?

Can you please verify the same?

dhanu_today
Creator
Creator
Author

In the s-100(ID)--0.05 and N-0.08--101 and E-0--102

So am getting the along with <=0 bucket and same way i have to apply for rest of the buckets.

Dhanu

Community Browser