Index/Match running slow

yoshiredz

New Member
Joined
Apr 12, 2022
Messages
7
Office Version
  1. 365
Platform
  1. Windows
I have a report that has shift information day on day for a month per person (there's over 1000 people, so lots of data).
Each individual shift is on a separate row (so 30 each)
I want to sort the data in a better way... for example - see below.
I have tried using - =FILTER('Shift Report'!$D:$D,('Shift Report'!$A:$A=Output!$A7)*('Shift Report'!$G:$G=Output!$AM$2)*('Shift Report'!$C:$C=Output!AM$5),0)
and also - =INDEX('Shift Report'!$D:$D,MATCH(1,('Shift Report'!$A:$A=Output!$A7)*('Shift Report'!$C:$C=Output!AO$5)*('Shift Report'!$G:$G=Output!AM$2),0))
as this uses the criteria of the name, date and week to insert the shift time.
problem is, it is taking a long time to calculate.
is there another way I can do this?
I do have some macros in the spreadsheet, which speeds up other things, but my knowledge doesn't stretch that far.
Any help is greatly appreciated :)
Thank you..

MonTueWedThu
NameHours10/10/202211/10/202212/10/202213/10/2022
StartEndStartEnd
Adams, Jen25
08:30:00​
14:30:00​
08:30:00​
14:30
Adamson, Andrew
37​
10:00:00​
18:30:00​
10:00:00​
18:30
 

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes
Limiting your references to a reasonable range will boost up the performance significantly. Poor excel is trying to index all of your rows :( E.g. $A1:$A10000 or $D1:$D10000.
Also try XLOOKUP function. I am not good at new 365 functions but they offer many practical solutions.
 
Upvote 0
Limiting your references to a reasonable range will boost up the performance significantly. Poor excel is trying to index all of your rows :( E.g. $A1:$A10000 or $D1:$D10000.
Also try XLOOKUP function. I am not good at new 365 functions but they offer many practical solutions.
Thank you. So forgive me and sorry to sound stupid, but how do I limit my range? The full data amount is going to be a lot more than that :(
I will have a look at xlookup too.
 
Upvote 0
Excel has 1.048.576 rows in total. How much more can your data be than 10.000? Then try, 100.000. But don't do all...
 
Upvote 0
Excel has 1.048.576 rows in total. How much more can your data be than 10.000? Then try, 100.000. But don't do all...
The total rows of data will be approx 36,000. So, other than doing my data in smaller amounts, there's no way I can speed up process?
 
Upvote 0
Try this for the second formula:
Excel Formula:
=XLOOKUP(Output!$A7&Output!AO$5&Output!AM$2,'Shift Report'!$A:$A&'Shift Report'!$C:$C&'Shift Report'!$G:$G,'Shift Report'!$D:$D)
I am also trying for the first time. So it may not work :) I hope this may speed up the things!
 
Upvote 0
Just limit the number of rows to about 50,000
Excel Formula:
=FILTER('Shift Report'!$D2:$D50000,('Shift Report'!$A2:$A50000=$A7)*('Shift Report'!$G2:$G50000=$AM$2)*('Shift Report'!$C2:$C50000=AM$5),0)
 
Upvote 0
Try this for the second formula:
Excel Formula:
=XLOOKUP(Output!$A7&Output!AO$5&Output!AM$2,'Shift Report'!$A:$A&'Shift Report'!$C:$C&'Shift Report'!$G:$G,'Shift Report'!$D:$D)
I am also trying for the first time. So it may not work :)
Thanks, I will have a look and report back :)
 
Upvote 0
I would expect the Xlookup to be slower than what you already have. Also you should always avoid using whole column references especially in array formulae.
 
Upvote 0
I would expect the Xlookup to be slower than what you already have. Also you should always avoid using whole column references especially in array formulae.
Is there a better alternative that you would suggest?
 
Upvote 0

Forum statistics

Threads
1,214,944
Messages
6,122,387
Members
449,080
Latest member
Armadillos

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