Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
rohitk1609
Master
Master

Rank by Particular Dimension value

Hi Techies,

I am facing a problem where I need to populate the rank by each Material so I can find the difference between top MAP to previous position MAP i.e  (101,4099,200 )  and (101,4090,100,) w.r.t to each and every Material, the data I have :

Test:

load

*

Inline

[

Material ,WERKS,MAP

101,4069,10,

101,4066,20

101,4090,100,

101,4099,200,

102,4069,30,

102,4066,50,

102,4090,100,

];


expected output:


Material ,WERKS,MAP,Rank

101,4069,10,1

101,4066,20,2

101,4090,100,3

101,4099,200,4

102,4069,30,1

102,4066,50,2

102,4090,100,3

Please take this on priority basis

Best,

Rohit



6 Replies
kenphamvn
Creator III
Creator III

Hi

Try

load *, AutoNumber(Material&WERKS,Material) as Rank

Resident Test;

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

Try this.

load

*,AutoNumber(WERKS,Material) as Rank

Inline

[

Material ,WERKS,MAP

101,4069,10,

101,4066,20

101,4090,100,

101,4099,200,

102,4069,30,

102,4066,50,

102,4090,100,

];

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
antoniotiman
Master III
Master III

AutoNumber(WERKS) as Rank

kusumanchir
Creator
Creator

Hi Rohit,

Please try this as your expression,

aggr(rank(-MAP),Material,WERKS)

Regards,

Rasly.K

sunny_talwar

Looking to do this in script or front end of the application?

rohitk1609
Master
Master
Author

I was trying to do it on back end and  AutoNumber(Material&WERKS,Material)  works fine.