Using AND in complicated look up feature

Lball

Board Regular
Joined
Oct 4, 2005
Messages
197
Hi All,

I am using a formula to search a saved chart of data to find the number of times an item appears in the chart. I used the following formula to get started...

=IF(ISERROR(INDEX(Chart,SMALL(IF(Fico<=$A$3,ROW(Fico)),ROW(1:1)),5)),"",INDEX(Chart,SMALL(IF(Fico<=$A$3,ROW(Fico)),ROW(1:1)),5))

Chart=whole data array
Fico=Column A of Chart
DocTYpe=Column B of Chart

I used A3 as input to find number times of occurance and list column E of chart for each occurance. It works great.

Here's my question...I really want this to be a search engine for the number of times my input boxes (A3 and B3) both occur at the same time in the Chart. Example: A3=620 and B3=SIVA, i want to print out the data in column 5 of chart for all matches of 620 to Fico and SIVA to DocType.
Anyone have an idea of how to integrate AND or another way to get the same results???
 

Some videos you may like

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.

acw

MrExcel MVP
Joined
Feb 13, 2004
Messages
4,814
Hi

Think I have the cell references and named ranges correct.
Assumes the output is going into Row 1.

=INDEX(chart!E:E,SMALL(IF((FICO=$A$#)*(DocType=$B$3),ROW(FICO),65536),ROW()))
array entered (ctrl, shift enter)

Format the cell as Format, Cell, Number, Custom,#;#;""

copy down as required.


Tony
 

Lball

Board Regular
Joined
Oct 4, 2005
Messages
197
Thank you for your input. I am having problems with the formula. It doesn't like the $A$#. Then i broke the formula down further to test areas, and its this part that doesn't work. First i have to change the "#" to something so i use a 3. I am getting a Num# error

SMALL(IF((FICO=$A$#)*(DocType=$B$3),ROW(FICO),65536),ROW()))

I'm trying to trouble shoot, but i don't know the reasoning behind $A$# or the * between the two. Can you send some more info. Or if i can help define things better i will. Please let me know.

Thanks for your help.
 

Aladin Akyurek

MrExcel MVP
Joined
Feb 14, 2002
Messages
85,201
Lball said:
Hi All,

I am using a formula to search a saved chart of data to find the number of times an item appears in the chart. I used the following formula to get started...

=IF(ISERROR(INDEX(Chart,SMALL(IF(Fico<=$A$3,ROW(Fico)),ROW(1:1)),5)),"",INDEX(Chart,SMALL(IF(Fico<=$A$3,ROW(Fico)),ROW(1:1)),5))

Chart=whole data array
Fico=Column A of Chart
DocTYpe=Column B of Chart

I used A3 as input to find number times of occurance and list column E of chart for each occurance. It works great.

Here's my question...I really want this to be a search engine for the number of times my input boxes (A3 and B3) both occur at the same time in the Chart. Example: A3=620 and B3=SIVA, i want to print out the data in column 5 of chart for all matches of 620 to Fico and SIVA to DocType.
Anyone have an idea of how to integrate AND or another way to get the same results???

Which cell house the first instance of this non-robust formula?
 

Watch MrExcel Video

Forum statistics

Threads
1,118,081
Messages
5,570,088
Members
412,310
Latest member
mark884
Top