INDEX data set, but results are sorted low to high

freeb1893

Board Regular
Joined
Jul 30, 2012
Messages
233
Office Version
  1. 365
Platform
  1. Windows
So I have a list of 50 records, some in the list are blank values, some in the list are numbers. There are no duplicate numbers in the list. Sometimes the list might be numbers 1 through 14 with 36 blanks, sometimes the list might be 1 through say 26 with 24 blanks. The numbers randomly located throughout the list of 50.

I want a formula to index this list of 50 and pull the results in order, so my 1st result cell is 1, 2nd result cell is 2, 3rd result cell is 3, etc. down to the largest number found in the array, ignoring blank.

Anyone know how to write this into a formula? Thanks in advance
 

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
If your list is A1:A50, and your first result cell is B2 (header in B1), put this formula in B2 and drag down:

=SMALL($A$1:$A$50,ROWS($B$2:$B2))


Edit: You may want to put an IFERROR around it to avoid errors at the end of your list.

=IFERROR(SMALL($A$1:$A$50,ROWS($B$2:$B2)),"")
 
Last edited:
Upvote 0

Forum statistics

Threads
1,215,463
Messages
6,124,963
Members
449,200
Latest member
indiansth

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