Look value above 0 on E and return A

douglascaixeta

New Member
Joined
Mar 21, 2009
Messages
45
Office Version
  1. 2019
Platform
  1. Windows
I would like to look at every value that is greater than zero in column E, and if its greater than zero, should return the value on column A on the same line.
But there are more than one line with values greater than 0, and should return every single name on column A, not just the first or the bigger.
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
What version of Excel are you using?
I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)

Also can you post some sample data along with expected results.

MrExcel has a tool called “XL2BB” that lets you post samples of your data that will allow us to copy/paste it to our Excel spreadsheets, so we can work with the same copy of data that you are. Instructions on using this tool can be found here: XL2BB Add-in

Note that there is also a "Test Here” forum on this board. This is a place where you can test using this tool (or any other posting techniques that you want to test) before trying to use those tools in your actual posts.
 
Upvote 0
And the data sample?
 
Upvote 0
Good Company.xlsx
ABCDE
19BananasApplesPineappleStrawberries
20A4204
21B0200
22C00250
23D0000
24E0000
25F0000
26G0053
27H0000
28I0000
29J0000
30K0000
31L0000
32M0000
Recipes Table


Would like to show A and J and respective numbers 4 and 3 if I select Strawberries.
 
Upvote 0
You still haven't shown you expected results. Do you want it in one cell, against each row or what?
 
Upvote 0
I would like to look at every value that is greater than zero in column E, and if its greater than zero, should return the value on column A on the same line.
If I do a simple formula it will return the zeros. The expected result if I select Strawberries is:
A 4
G 3
 
Upvote 0
Maybe
+Fluff 1.xlsm
ABCDEFG
19BananasApplesPineappleStrawberries
20A4204A4,G3
21B0200
22C00250
23D0000
24E0000
25F0000
26G0053
27H0000
28I0000
29J0000
30K0000
31L0000
32M0000
Main
Cell Formulas
RangeFormula
G20G20=TEXTJOIN(",",1,IF(E20:E32>0,A20:A32&E20:E32,""))
Press CTRL+SHIFT+ENTER to enter array formulas.


Please don't forget to update your profile to show which version/platform you are using.
 
Upvote 0
Ok that is good. I wasn't looking to put all info on the same cell, but that works fine.

Can we make a way to select the name and the formula will search for the correct column rather than manually select the column? This way I can type the name and it will give me the values, instead of having to manually select the correct column.

Like this: *But having on the same cell is ok too.

BananasA4
ApplesA2B2
PineappleC25G5
StrawberriesA4G3
 
Upvote 0
How about
+Fluff 1.xlsm
ABCDEFGH
19BananasApplesPineappleStrawberries
20A4204BananasA4
21B0200ApplesA2, B2
22C00250PineappleC25, G5
23D0000StrawberriesA4, G3
24E0000
25F0000
26G0053
27H0000
28I0000
29J0000
30K0000
31L0000
32M0000
33
34
Main
Cell Formulas
RangeFormula
H20:H23H20=TEXTJOIN(", ",,IF(($B$19:$E$19=$G20)*($B$20:$E$32>0),$A$20:$A$32&INDEX($B$20:$E$32,,MATCH(G20,$B$19:$E$19,0)),""))
Press CTRL+SHIFT+ENTER to enter array formulas.
 
Upvote 0
Solution

Forum statistics

Threads
1,214,517
Messages
6,119,984
Members
448,935
Latest member
ijat

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