Announcements
cancel
Showing results for
Did you mean:
Specialist

## rank in ascending order

set analysis:

=Codigo & ' ' & aggr(concat(aggr(',' &'Filial ' & Filial& ' Stock ' & sum(Estoque)& ' RK ' & rank(sum(Estoque)), Codigo, Filial)), Codigo)

result:

100 ,Filial 1 Stock 100 RK 1,Filial 2 Stock 99 RK 2,Filial 3 Stock 88 RK 3
101 ,Filial 1 Stock 150 RK 2,Filial 2 Stock 151 RK 1,Filial 3 Stock 44 RK 3
102 ,Filial 1 Stock 380 RK 2,Filial 2 Stock 341 RK 3,Filial 3 Stock 560 RK 1

right:✔️

100 ,Filial 1 Stock 100 RK 1,Filial 2 Stock 99 RK 2,Filial 3 Stock 88 RK 3
101 ,Filial 2 Stock 151 RK 1,Filial 1 Stock 150 RK 2,Filial 3 Stock 44 RK 3
102 ,Filial 3 Stock 560 RK 1,Filial 1 Stock 380 RK 2,Filial 2 Stock 341 RK 3

can someone help me thank you.

Neves
1 Solution

Accepted Solutions

@Ribeiro  try below. see the attached

``=code & ' ' & concat(aggr(' Branch ' & Branch & ' Stock ' & sum(stock)& ' RK ' & rank(sum(stock)), code, Branch),'',aggr(rank(sum(stock)),code,Branch))``

``=code & ' ' & concat(aggr(' Branch ' & Branch & ' Stock ' & sum(stock)& ' RK ' & rank(sum(stock)), code, Branch),'',aggr(rank(sum(stock)),code,Branch))``