How to repeating sort in excel

ingkafi

New Member
Joined
Oct 28, 2021
Messages
6
Office Version
  1. 2019
Platform
  1. Windows
Hi everyone, i'm struggling to sort in Excel. I have a labelled data from 1-5. What i want is the data sorted with repeated number. To help you visualize see the picture below. Is there any way to resolve this? Thank you
1635416625842.png
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.
MrExcelPlayground4.xlsx
FGHIJ
11Data 11Data 1
21Data 22Data 3
32Data 33Data 5
42Data 44Data 7
53Data 55Data 9
63Data 61Data 2
74Data 72Data 4
84Data 83Data 6
95Data 94Data 8
105Data 105Data 10
Sheet25
Cell Formulas
RangeFormula
I1:J10I1=INDEX(F1:G10,MOD(SEQUENCE(COUNT(F1:F10),1,1,2),COUNT(F1:F10))+IF(SEQUENCE(COUNT(F1:F10))>COUNT(F1:F10)/2,1,0),{1,2})
Dynamic array formulas.
 
Upvote 0
Thank you for the answer, but it looks like i'm having trouble using the formula as seen below
1635425784839.png

How to solve this?
 
Upvote 0
What version of excel do you have? I thought it said 365 before - and it says 2021 now.

See if your excel recognizes the sequence function or the {}
 
Upvote 0
@JamesCanale Xl2021 has all the latest functions, so that shouldn't be a problem.

@ingkafi what do you normally use to separate the arguments in a function? Is it a comma, or semi-colon?
 
Upvote 0
Probably a better way than this:
MrExcelPlayground4.xlsx
VWXYZ
11Data 11Data 1
21Data 22Data 3
32Data 33Data 5
42Data 44Data 7
53Data 55Data 9
63Data 61Data 2
74Data 72Data 4
84Data 83Data 6
95Data 94Data 8
105Data 105Data 10
Sheet25
Cell Formulas
RangeFormula
Y1:Y10Y1=INDEX($V$1:$W$10,MOD((ROW()-ROW($V$1)+1)*2-1,ROWS($V$1:$V$10))+IF((ROW()-ROW($V$1)+1)>ROWS($V$1:$V$10)/2,1,0),1)
Z1:Z10Z1=INDEX($V$1:$W$10,MOD((ROW()-ROW($V$1)+1)*2-1,ROWS($V$1:$V$10))+IF((ROW()-ROW($V$1)+1)>ROWS($V$1:$V$10)/2,1,0),2)
 
Upvote 0

Forum statistics

Threads
1,223,231
Messages
6,170,884
Members
452,364
Latest member
springate

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