Index Columns with formula - Help

darrenmccoy

New Member
Joined
Mar 26, 2019
Messages
37
Office Version
  1. 2019
Hi Experts, Can you please show me a formula to index all the ID's into one column? The columns are all different number of rows. Thanks

ContactIDContactIDContactIDContactIDContactID
1012984410129173904526990741229074288
10371234117182509074122929292210062097
10527196120918779074288929348010072521
11625021202977029074933950887311276250
11718507252674579293480974559414822020
11958065255219119316463995000220779918
137013293076655895088731007252129995999
139571623353352396323471012333631147578
163743993580194297455941015067835189996
205117564114905999414151015605039564871
221643996026969399448541020538561239083
222038366119998499500021020692180538609
2313720061239083100389921020838187217481
2878833861983304100620971022498688378052
2879109170369885100725211035222091813644
28802324743750791012917310371621
28863649747104691020692110527196
754956811030776510973181
768053331035210011072581
770468141037162111183118
772754931048033511284862
1097318111536983
1118311811718250
1127625011718507
1128486212091877
11536983
11552432
11718250
11718710
11774458
11971550
 

Excel Facts

Test for Multiple Conditions in IF?
Use AND(test, test, test, test) or OR(test, test, test, ...) as the logical_test argument of IF.
What version of Excel are you using?

I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)
 
Upvote 0
As your Contract ID's all appear to be numeric, this should work (Office 365 only).
Excel Formula:
=UNIQUE(SMALL($A$2:$E$50,SEQUENCE(COUNT($A$2:$E$50))))
 
Upvote 0
As your Contract ID's all appear to be numeric, this should work (Office 365 only).
Excel Formula:
=UNIQUE(SMALL($A$2:$E$50,SEQUENCE(COUNT($A$2:$E$50))))

HI, Thanks, I gave this a try but it didn't like it.
Came up with a #NAME? error
I tried it in GSheets too, and it just indexed one value.
This is the version Im using.

1615554427195.png
 
Upvote 0
Thanks for that, how about
+Fluff 1.xlsm
ABCDEFH
1ContactIDContactIDContactIDContactIDContactID
210129844101291739045269907412290742889045269
3103712341171825090741229292922100620979074122
4105271961209187790742889293480100725219074122
5116250212029770290749339508873112762509074288
6117185072526745792934809745594148220209074288
7119580652552191193164639950002207799189074933
81370132930766558950887310072521299959999292922
91395716233533523963234710123336311475789293480
101637439935801942974559410150678351899969293480
112051175641149059994141510156050395648719316463
122216439960269693994485410205385612390839508873
132220383661199984995000210206921805386099508873
1423137200612390831003899210208381872174819632347
1528788338619833041006209710224986883780529745594
1628791091703698851007252110352220918136449745594
17288023247437507910129173103716219941415
18288636497471046910206921105271969944854
197549568110307765109731819950002
207680533310352100110725819950002
2177046814103716211118311810038992
2277275493104803351128486210062097
23109731811153698310062097
24111831181171825010072521
25112762501171850710072521
26112848621209187710072521
271153698310123336
281155243210129173
291171825010129173
301171871010129844
311177445810150678
321197155010156050
3310205385
3410206921
Main
Cell Formulas
RangeFormula
H2:H34H2=AGGREGATE(15,6,$A$2:$E$32/($A$2:$E$32<>""),ROWS(H$2:H2))
 
Upvote 0
FYI for any future readers of this post. This formula works perfectly in GSheets.
=UNIQUE({A1:A;B1:B;C1:C;D1:D;E1:E}) in Cell F1
But I cant get it to work in Excel.
 
Upvote 0
Thank you, can you tell me what the (15,6 part of the formula means?
Those are both function parameters, 15 is the function number for small, which is used to list your ID's in ascending order. If you change it to 14, the function number for large, then they would be in descending order. The 6 parameter tells the function to ignore any errors generated in the array, which would be caused here by the empty cells.

All of this information, and more, can be found in the built in help file that comes with Excel.
This formula works perfectly in GSheets.
=UNIQUE({A1:A;B1:B;C1:C;D1:D;E1:E}) in Cell F1
But I cant get it to work in Excel.
The syntax of google formulas is different to Excel, it might be possible to make similar work, but not identical.
Also, you're using Excel 2019, which doesn't have the UNIQUE function. That requires an up to date office 365 subscription. It will likely be included in the next non-subscription version of excel (assuming that one is released) but that remains to be seen.
 
Upvote 0
If you want unique vales only then you can use
Excel Formula:
=AGGREGATE(15,6,$A$2:$E$32/($A$2:$E$32<>"")/(ISNA(MATCH($A$2:$E$32,H$1:H1,0))),1)
 
Upvote 0
Solution

Forum statistics

Threads
1,215,772
Messages
6,126,811
Members
449,339
Latest member
Cap N

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