Qlik Community

QlikView Publisher

Discussion Board for collaboration on QlikView Publisher.

mohamed_ahid
Contributor III

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

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

See this blog post: Recipe for a Pareto Analysis


talk is cheap, supply exceeds demand

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

=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
Contributor III

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

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

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

Provide Sample data to work...

mohamed_ahid
Contributor III

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

Here .

thanx

mohamed_ahid
Contributor III

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

Any advises Plz ?

MVP
MVP

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

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
Contributor III

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

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

Community Browser