on 02-18-2014 8:01 AM
Hello Experts,
I have a situation which seems really simple but have consumed a lot of my time. The requirement is to sort the INDEX with respect to PartsQuantity in ascending order. Well, I tried the below mapping which seemed obvious to me. But I got some unexpected results !! Can someone please walk me through whats wrong with the below mapping or suggest what can be done to rectify the problem ! It'd be really helpful.
Thanks in Advance
Sam
Hi Sam,
In your diplay queue result the index is sorted with respect to ascending order of PartQuantity values. If you check the values of PartQuanity, the smallest value is '12' and the corresponding index value is '30' which is on top in your result list, which is a correct output as per sortbykey function.
Amol
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Is in ascending order by default
30 --> 12
110 --> 64
40 --> 200
10 --> 288
...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sam,
Double-click the sortByKey and then choose ascending order.
Regards,
Mark
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sam
Which are the unexpected results?
Regards
Javi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
81 | |
25 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.