Function to Sort data based on value to the right

hajiali

Well-known Member
Joined
Sep 8, 2018
Messages
624
Office Version
  1. 2016
Platform
  1. Windows
A10
B5
C20
D1
E13
F15
G18
H2
I6
J7

<tbody>
</tbody>


Using the above table column A is an array Function that pulls data from another sheet which will Every time I sort Column B to Sort A to Z it always goes back to the normal Sort. I want column C to pull the data form Column A and List them based on the order of the number to the right so. So Results for Column C Should be as Follows:

D
H
B
I
J
A
E
F
G
C

<tbody>
</tbody>
 
Last edited:

Excel Facts

Control Word Wrap
Press Alt+Enter to move to a new row in a cell. Lets you control where the words wrap.
As long as your data won't have duplicates, as in your example, then this will work:

ABC
1A10D
2B5H
3C20B
4D1I
5E13J
6F15A
7G18E
8H2F
9I6G
10J7C

<colgroup><col style="width: 25pxpx"><col><col><col></colgroup><thead>
</thead><tbody>
</tbody>
hajiali

Worksheet Formulas
CellFormula
C1
=INDEX($A$1:$A$10,MATCH(AGGREGATE(15,6,$B$1:$B$10,ROW()),$B$1:$B$10,0))

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>
 
Upvote 0

Forum statistics

Threads
1,214,534
Messages
6,120,086
Members
448,944
Latest member
sharmarick

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top