Indirect Function Delivering Blank Cell Results

jonholm619

New Member
Joined
Apr 6, 2016
Messages
11
Hello,


I am coming across issues with results being delivered as a result of substituting the indirect function for the range that had previously existed. Initially I had the following as my formula, which delivered the results I needed:
{=IF(ISERROR(INDEX('FTP payment poly'!$P$5003:$R$5025,SMALL(IF('FTP payment poly'!$P$5003:$R$5025=$A3,ROW('FTP payment poly'!$P$5003:$R$5025)),ROW($1:$1)),3)),"",INDEX('FTP payment poly'!$P$5003:$R$5025,SMALL(IF('FTP payment poly'!$P$5003:$R$5025=$A3,ROW('FTP payment poly'!$P$5003:$R$5025))),ROW($1:$1)),3))}
I then substituted my range with the following (which left me with blank cells (even after ensuring I used CTRL+SHIFT+ENT to activate the array:
{=IF(ISERROR(INDEX(INDIRECT('FTP payment poly'!$AA3),SMALL(IF(INDIRECT('FTP payment poly'!$AA3)=$A3,ROW(INDIRECT('FTP payment poly'!$AA3))),ROW($1:$1)),3)),"",INDEX(INDIRECT('FTP payment poly'!$AA3),SMALL(IF(INDIRECT('FTP payment poly'!$AA3)=$A3,ROW(INDIRECT('FTP payment poly'!$AA3))),ROW($1:$1)),3))}


The above referenced range where 'FTP payment poly'! exists is located on another sheet within the workbook and is the lookup table. This will be the second table displayed below. The first table shown below is where the columns B-F carry the referenced formula above. Columns G-K are helper columns I created formulas in to come up with the appropriate range for the lookup.


What I am attempting to do is run down the list, and produce the next five customer transactions that occurred after a specified return. The array works, but as stated earlier only prior to inserting the indirect formula. Once I use the indirect formula, my results do not exist. I do not get any error messages, simply blank cells. The results delivered prior to inserting the indirect function, were 1st Status for customer 000253073 was 4/8/15 and 2nd Status for customer 000253073 was 4/9/15. Technically, the formula above would have been slightly changed where ROW($1:$1) exists for 1st Status to include ROW($2:$2) would exist for 2nd Status.


Please note I have simplified this example and in reality there are several thousands of rows that these customers belong to and the reason for the need for the array function.


Table 1:
ABCDEFGHIJK
1Customer1st Status2nd Status3rd Status4th Status5th StatusRow where first customer is foundTransaction ID where a customer and their return is foundRow where the transaction ID appearsRow to beginEndingrow
2000253073500083793500250035025
3000124580500582532500750085025
4000252063501083986501050115025
5000257283501283850501250135025
6000252725501484683501750185025
7000254700501983587501950205025
8000173540502082530502050215025
9000112938502182534502350245025
10000244966502483870502450255025

<tbody>
</tbody>




Table 2:
PQR
5000253073Processed4/5/15
5001253073Processed4/6/15
5002253073Processed4/7/15
5003253073Processed4/8/15
5004253073Processed4/9/15
5005124580Processed4/3/15

<tbody>
</tbody>




Thank you in advance!


~Jon
 

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand
I didn't take the time to dig all the way into your new formula, but some observations are;

Why change your formula if it was working...?
&
The INDIRECT formula converts a text to a reference, to show a text,you do so by putting it in quotes...
&
What you have in the INDIRECT formula is a one cell reference, are you meaning to do that;
( i.e.... $AA3 ) instead of: $P$5003:$R$5025 ???

( These are just some quick thoughts, perhaps your answers will stir up some help )
 
Upvote 0
Hey Chris, thank you for the feedback...The reason for the change is because without using the indirect formula, I would have to manually type into each cell the range because the range changes as I move throughout the various rows.

I tried two different solutions to your advice of adding quotes. The first, INDIRECT('FTP payment poly'!"$AA3"... gave me an error message stating that there was a problem with the formula. The second, INDIRECT("'FTP payment poly'!$AA3"...gave me a blank result.

Any additional help would be greatly appreciated.

Thanks!
 
Upvote 0
First of all as I replicated your situation, you have an extra closing parenthesis in your second SMALL formula to where it doesn't allow the ROW formula to be a part of it.

The INDIRECT formula is picky...

What do you have inside of cell AA3...?

If you have: P5003:R5025 or $P$5003:$R$5025 it should work, as long as you are meaning to refer to that other tab.

Because you are telling it to go to the 'FTP payment poly'! tab and then on that tab go to the text mentioned in cell $AA3, which should be the range I just mentioned...

Then when you copy it down that reference will change to Cell: $AA4 , so you may want to lock that reference to: $AA$3

I am not seeing your spreadsheet, so if I am missing something forgive me...
Just keep in mind that the INDIRECT is strictly looking at everything as text and then converting it.
I hope this helps in some way.
 
Upvote 0
Upvote 0

Forum statistics

Threads
1,215,607
Messages
6,125,818
Members
449,262
Latest member
hideto94

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