Returning a text value from an array

Copper Contributor

I have an array.  and want to search a specific column for a value greater than 0 in the array.  if i find a value greater than 0 i want to return the text entered in a different column of the array.  See below for a picture.

 

i want to search column labeled 1 and any cell with a value greater then 0 will then return the text from the cell next to in from the column titled "category"

 

for example i search Column labeled 1 and find cell with "3" in it.  cell with Adhesive Issues will be copied and returned to another cell.  Also column with a 1 will return "did not cool" etc.

    1 2 3 4 5 6 7 8
Category Number of reports Jan Feb Mar Apr May Jun Jul Aug
Adhesive Issues   3 0 0 0 0 0 0 1
Belt Issues   0 0 0 0 0 0 0 0
Broken Cradle   0 0 0 0 0 0 0 0
Broken Roller Ball   0 0 0 0 0 0 0 0
Broken Seal   0 0 0 0 0 0 0 0
Broken Sprayer   0 0 0 0 0 0 0 0
Burning Effect-Not a Claim (BeKoool & OTC Only)   0 0 0 0 0 0 0 0
Color Bled   0 0 0 0 0 0 0 0
Contents Leaking   0 0 0 0 0 0 0 0
Damaged Property   0 0 0 0 0 0 0 0
Did Not Cool   1 1 0 0 0 0 0 0
Difficult to Open   0 0 0 0 0 0 0 0
Dried Out   0 2 1 0 0 1 0 0
Ineffective (Medical Device & OTC Only)   0 0 0 0 0 0 0 0
Injury   1 1 0 0 0 0 0 0
Low Duration   0 0 0 0 0 0 0 0
6 Replies

Hi,

 

It could be like

=IFNA(INDEX(<category column>, MATCH(<number>,<label column>,0)),"")

Thank you 

That did not work for what I wanted it to do

If you attach your sample as Excel file we could give you concrete formula for that

There is a similar case that based on a selected row header (yours is column header) to get the list of data in a row (yours is column), and then return the column headers of the data (yours is to return row header).

 

I have attached an excel file that may explain better

Hi,

 

When the approach approximately as Willy suggested. The formula in A43 will be

=IFERROR(
 INDEX(A$3:A$34,
   SMALL(
      IF(
         OFFSET($B$2,1,MATCH($B$42,$B$2:$M$2,0)-1,
            MATCH("Total",$A$1:$A$35,0)-MATCH("Category",$A$1:$A$35,0)-1) >0,
         ROW(A$3:A$34)-ROW(A$2)
      ),
      ROWS(A$3:A3)
  )
 ),
 "")

(that is an array formula entered by Ctrl+Shift+Enter), an copy it down.

Within OFFSET first MATCH defines which column to take based on month name and the second MATCH calculates number of rows within the list (between Category and Total).

 

How the formula works is here http://www.exceltactics.com/make-filtered-list-sub-arrays-excel-using-small/4/, first what I found, but there are quite a lot similar posts.

 

Please see attached.