Help pulling row information from a list using IF

%3CLINGO-SUB%20id%3D%22lingo-sub-1891521%22%20slang%3D%22en-US%22%3EHelp%20pulling%20row%20information%20from%20a%20list%20using%20IF%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1891521%22%20slang%3D%22en-US%22%3E%3CP%3EI'm%20trying%20to%20pull%20information%20from%20a%20row%20in%20a%20separate%20sheet%20using%20if%20to%20see%20if%20it%20meets%20the%20criteria%20within%20a%20column.%20e.g.%20if%20a%20cell%20in%20column%20A%20%3D%203%2C%20I%20then%20want%20it%20to%20show%20the%20information%20from%20column%20B%20from%20the%20row%20where%20it%20found%203.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22BriannaYK_0-1605545569566.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F233799iE8590F126971A273%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22BriannaYK_0-1605545569566.png%22%20alt%3D%22BriannaYK_0-1605545569566.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3EIn%20the%20screenshot%20I%20can%20see%20there%20is%20one%20TRUE%20answer%20where%20the%20condition%20has%20been%20met%20and%20the%204504.75%20that%20I'm%20looking%20for%20has%20been%20identified%20(below%20%22Value_if_false)%20but%20the%20cell%20still%20calculates%20as%20zero.%3C%2FP%3E%3CP%3EHelp!%20Thanks!%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1891521%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExcel%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EFormulas%20and%20Functions%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1891600%22%20slang%3D%22en-US%22%3ERe%3A%20Help%20pulling%20row%20information%20from%20a%20list%20using%20IF%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1891600%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F870624%22%20target%3D%22_blank%22%3E%40BriannaYK%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI've%20recently%20helped%20someone%20with%20a%20similar%20issue%20has%20already%20applied%20an%20array%20formula%20to%20pull%20relevant%20information%20into%20separate%20tabs%20in%20real-time.%20(%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fexcel%2Frecalculate-sheets%2Fm-p%2F1890665%22%20target%3D%22_self%22%3ELink%3C%2FA%3E)%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ECan%20you%20attach%20your%20workbook%20to%20get%20a%20better%20idea%20of%20the%20data%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1891642%22%20slang%3D%22en-US%22%3ERe%3A%20Help%20pulling%20row%20information%20from%20a%20list%20using%20IF%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1891642%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F867265%22%20target%3D%22_blank%22%3E%40adversi%3C%2FA%3E%26nbsp%3BHi%2C%20Sorry%20I'm%20not%20sure%20if%20I%20really%20understand%20the%20formula%2Fdiscussion%20in%20the%20link%20you%20provided%20and%20I'm%20afraid%20I%20can't%20attach%20the%20document%20in%20question%20%3CLI-EMOJI%20id%3D%22lia_disappointed-face%22%20title%3D%22%3Adisappointed_face%3A%22%3E%3C%2FLI-EMOJI%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20was%20hoping%20someone%20could%20tell%20me%20what%20needs%20to%20be%20added%20to%20my%20formula%20so%20that%20only%20the%20cell%20amount%20from%20the%20row%20where%20the%20condition%20is%20true%2C%20shows.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1891658%22%20slang%3D%22en-US%22%3ERe%3A%20Help%20pulling%20row%20information%20from%20a%20list%20using%20IF%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1891658%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F870624%22%20target%3D%22_blank%22%3E%40BriannaYK%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThe%20reason%20sending%20a%20template%20would%20help%20is%20to%20understand%20the%20data%20structure%20and%20best%20formula%20to%20apply%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E1.%20Will%20there%20be%20more%20than%20one%20row%20being%20pulled%20by%20the%20matched%20logical%20test%3F%3C%2FP%3E%3CP%3E2.%20How%20many%20columns%20of%20data%20are%20in%20a%20row%3F%3C%2FP%3E%3CP%3E3.%20What%20is%20the%20end%20goal%20of%20the%20workbook%20-%20will%20there%20only%20be%20one%20tab%20with%20final%20results%20that%20you%20want%20automatically%20updated%20when%20the%20condition%20changes%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThe%20formula%20will%20change%20depending%20on%20the%20answers%20of%20the%20question%20above%2C%20whether%20it%20a%20simple%20IF%20can%20do%20the%20job%20or%20if%20an%20array%20needs%20to%20be%20created.%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
New Contributor

I'm trying to pull information from a row in a separate sheet using if to see if it meets the criteria within a column. e.g. if a cell in column A = 3, I then want it to show the information from column B from the row where it found 3.

 

BriannaYK_0-1605545569566.png

In the screenshot I can see there is one TRUE answer where the condition has been met and the 4504.75 that I'm looking for has been identified (below "Value_if_false) but the cell still calculates as zero.

Help! Thanks!

6 Replies
Highlighted

@BriannaYK 

I've recently helped someone with a similar issue that has already applied an array formula to pull relevant information into separate tabs in real-time. (Link)

 

Can you attach your workbook to get a better idea of the data?

Highlighted

@adversi Hi, Sorry I'm not sure if I really understand the formula/discussion in the link you provided and I'm afraid I can't attach the document in question  

I was hoping someone could tell me what needs to be added to my formula so that only the cell amount from the row where the condition is true, shows.

Highlighted

@BriannaYK 

The reason sending a template would help is to understand the data structure and best formula to apply:

 

1. Will there be more than one row being pulled by the matched logical test?

2. How many columns of data are in a row?

3. What is the end goal of the workbook - will there only be one tab with final results that you want automatically updated when the condition changes?

 

The formula will change depending on the answers of the question above, whether it a simple IF can do the job or if an array needs to be created.

Highlighted

@BriannaYK 

IMHO, everything works correctly in your case. Function return array of values, if condition is FALSE the value in array is equal to zero, if TRUE - to some number. 

If you are on subscription model, you shall be on Excel with Dynamic Arrays which returns entire such array. The answer will be 0, 0, 4500, 0, etc

Pre-DA Excel will return only first element of such array, e.g. zero. And that's what formula dialogue shows.

 

If you'd like to return element from third position of the result using the condition TRUE, tat will be another formula. Which one it's better to discuss on your sample.

Highlighted

Thanks for your help @Sergei Baklan. Now I understand and yes, I would like only the element with the result using the condition TRUE to be displayed. What formula should I be using for this?

Highlighted

@BriannaYK 

Formulas could be different, also depends on your version of Excel. This one shall work in any case

=INDEX('202022'!$K$2:$K$36,MATCH(140807,'202022'!$D$2:$D$36,0))

Better keep lookup value in the cell, let say A1
=INDEX('202022'!$K$2:$K$36,MATCH(A1,'202022'!$D$2:$D$36,0))