Row not coming across - formula help!!!

fffzac

New Member
Joined
May 30, 2018
Messages
5
Hi,

I am looking to bring data over from one sheet to another when it matches a certain value on the first sheet. The current formula I am using is:

{=IF(ISERROR(INDEX(Sheet2!$A$2:$K$4970,SMALL(IF(Sheet2!$A$2:$A$4970='Sheet1'!$C$14,ROW(Sheet2!$A$2:$A$4970)),ROW(1:1)),0)),"",INDEX(Sheet2!$A$2:$K$4970,SMALL(IF(Sheet2!$A$2:$A$4970='Sheet1'!$C$14,ROW(Sheet2!$A$2:$A$4970)),ROW(1:1)),5))}

The problem I am having is that the first row of data I need is not coming across to the sheet and the last row of data being brought across is from the next dataset.

I think its something to do with the ROW() but cant work it out.

Any ideas?
 

Excel Facts

Why are there 1,048,576 rows in Excel?
The Excel team increased the size of the grid in 2007. There are 2^20 rows and 2^14 columns for a total of 17 billion cells.
Looks like you're trying to retrieve a value if it exists else return blank.

Try

non array formula
=IFERROR(INDEX(Sheet2!A$2:A$4970,AGGREGATE(15,6,ROW(Sheet2!A$2:A$4970)/(Sheet2!A$2:A$4970=Sheet1!$C$14),ROWS(A$2:A4970)),1),"")

or array formula
=IFERROR(INDEX(Sheet2!$A$2:$A$4970,SMALL(IF((Sheet2!$A$2:$A$4970=Sheet1!$C$14),ROW($A$2:$A$4970)),ROW(A1))-(ROW(A$2)-1),1),"")
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,176
Members
453,021
Latest member
Justyna P

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