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: 
mohamed_ahid
Partner - Specialist
Partner - Specialist

how to get the number of bills that are 80% of my turnover

HI all

i'm trying to do a calculation on a table .

I have a bill's table and i want to get the number of bills that makes almost 80 % of my total revenue .

exemple :

in my bills table i have 100 000$ of revenue  and 63574 bills . the result must be like this way :

57489 of bills = 80 000 $ and 6085 of bills = 20 000 $ .

How can i acheive that plz?

thanx

8 Replies
Gysbert_Wassenaar

See this blog post: Recipe for a Pareto Analysis


talk is cheap, supply exceeds demand
MK_QSL
MVP
MVP

=Count(If(Aggr(RangeSum(Top(Sum(Amount), 1, RowNo())) / RangeSum(Top(Sum(Amount), 1, NoOfRows())), Bill) < 0.8, Bill, Null()))

The above expression will give you COUNT Of bills covering 80% amount of total bills

Below will give you for rest 20%

COUNT(TOTAL DISTINCT Bill)-Count(If(Aggr(RangeSum(Top(Sum(Amount), 1, RowNo())) / RangeSum(Top(Sum(Amount), 1, NoOfRows())), Bill) < 0.8, Bill, Null()))

mohamed_ahid
Partner - Specialist
Partner - Specialist
Author

thx all for your responses.

Manish , in my case i dont have a bill number , i tried a recno and it's giving nothing .

Anu idea or suggestion ?

Thx

regards

MK_QSL
MVP
MVP

Provide Sample data to work...

mohamed_ahid
Partner - Specialist
Partner - Specialist
Author

Here .

thanx

mohamed_ahid
Partner - Specialist
Partner - Specialist
Author

Any advises Plz ?

tresesco
MVP
MVP

In your sample, sum({<[Flag Source]={13}>} Flux) - is it giving you the turn over? If so, Sep14 - 6822, 80%->5457. There would be no ID qualifying. Am I missing something?

mohamed_ahid
Partner - Specialist
Partner - Specialist
Author

yes exactly , the turn over is sum({<[Flag Source]={13}>} Flux) . and i want to display tha value of 80% of it .

Beside this display also the value of id duree matching to the last value of the 80% of turne over .

Thx