Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
dhanu_today
Creator
Creator

Nested Count

Hi Everyone,

Can any one help me as per the attached requirement.I have to develop the logic in front end level because the sample data whatever the fields we have is coming from various tables.

Thanks in advance,

Dhanu

1 Solution

Accepted Solutions
qlikpahadi07
Specialist
Specialist

Hi Dhanu,

was that helpful ?

View solution in original post

20 Replies
dhanu_today
Creator
Creator
Author

Any one is there for hint .....

Thanks,

Dhanu

MK_QSL
MVP
MVP

What is the COUNT? i.e what is the logic you used to count?

dhanu_today
Creator
Creator
Author

Thanks...For in the exp1 i have counted the value based on the No. of accounts.

For Exp2--the sum of balances and for exp3 is sum(balance)/Count(accounts)

Main logic i have to do is based on the exp3 values i have to create the bucket and their respective no. of accounts.

e.g. if exp3 is 5000 then we have to show the how many accounts are in that bucket range.

Refer the attached output.

Let me know in case of any information my side.

Thanks ,

Dhanu

MK_QSL
MVP
MVP

SegemntCount(Accounts)sum(Balance)EXP2/EXP1<= 0 and <2000>=2000 AND <30000>=30000 AND <100000>= 100000
PRB718000025714.290200
SB635424559040.830020
CBC918358120397.890100

Sorry, still have doubt.

Can you tell me how the bold and underlined value coming?

The logic is apply to expression 3? or I am missing something?

dhanu_today
Creator
Creator
Author

Thanks for your time...The Bold and underline values(2 in PRB) are the count of accounts which are having the balance 20000 and 28000(in the Data of excel) so they are in the bucket of >=20000 and <100000.

Same wise for SB and CBC also.

Its my mistake in the out put sheet i wrote >=2000 instead of >=20000.

Let me know for any clarifications.

MK_QSL
MVP
MVP

You can use below expressions

COUNT({<Balance = {'>=0<20000'}>}Accounts)

COUNT({<Balance = {'>=20000<30000'}>}Accounts)

COUNT({<Balance = {'>=30000<100000'}>}Accounts)

COUNT({<Balance = {'>100000'}>}Accounts)

Let me know if these are not working...

dhanu_today
Creator
Creator
Author

Let me try the same and will get back....

dhanu_today
Creator
Creator
Author

Thanks ...But  script is not filling my requirement....It is giving the count of accounts using the field balance and for bucket as well.

We have to consider the exp3 result as balance(like derived balance) and then we have to count the no. of accounts based on the exp3 result bucket(not on the basis of existing balance).

Let me know for any clarifications.

Thanks,

Dhanu

MK_QSL
MVP
MVP

Ok... using the above mentioned criteria, let me know that the result you have shown in the excel file is accurate or the assumed one?