Look for Cell Data in Cell Array, and Cell Data in Row Array and if match show this Cell Data

Iccreamann21

New Member
Joined
Sep 25, 2013
Messages
48
Office Version
  1. 365
Platform
  1. Windows
Look for Cell Data in Cell Array, and Cell Data in Row Array and if match show this Cell Data

LPA findings sheet - 2024.xlsx
ABCDEFGHIJKLMNOPQRSTUVWXYZAAABACADAEAFAGAHAIAJAKALAMANAOAPAQARASATAUAVAWAXAYAZBABB
1Name2IDCompletion timeSTATIONOperator NameNumberShould BeMonthJanuaryFebruary
2John17107/2/24 8:58:28Engine Line 060LHMalcolm12look for A2, in column I:I, and then look for F2 in the row that A2 was found and then show the Week number in row 3WeekWeek 1Week 2Week 3Week 4Week 5Week 6Week 7Week 8Week 9
3Bob17117/2/24 8:58:28Main Line 2 KittingErica 59Week 6Dates1/11/21/31/41/51/81/91/101/111/121/151/161/171/181/191/221/231/241/251/261/291/301/312/12/22/52/62/72/82/92/122/132/142/152/162/192/202/212/222/232/262/272/282/293/1
4Mark17127/2/24 8:58:28Main Line 2 020LHBrittany 601st Week Seen
5Mark17137/2/24 8:58:28Main Line 1 020LHJay 61James111
6Mark17147/2/24 8:58:28Main Line 5 020LHAdam62John1212
7Dave17157/2/24 8:58:28Main Line 8 020LHMalcolm63Bill515
8Dave17167/2/24 8:58:28Main Line 2 020RHAdam7Bob259
9Justin17177/2/24 8:58:28Main Line 2 030LHJosh30Josh919
10Harold17187/2/24 8:58:28Main Line 2 030RHJay 31Dave63x63x123715
11Mark17197/2/24 8:58:28Main Line 2 020LHBrittany 602nd Week SeenMark62x61x6061555912
12Mark17207/2/24 8:58:28Main Line 2 020LHBrittany 603rd Week SeenTim3x24x9020426486
13Dalton3x25x9121436587
14Harold5x26x9222446688
15Justin6x27x9330456789
Sheet2
 

Excel Facts

Easy bullets in Excel
If you have a numeric keypad, press Alt+7 on numeric keypad to type a bullet in Excel.
I am not sure whether I understand it correctly. This should return the corresponding week number:

Excel Formula:
=LET(
headers,TOROW(IFERROR(EXPAND(TOROW($J$2:$BB$2,1),5),TOROW($J$2:$BB$2,1)),,1),
row,INDEX($J$5:$BB$15,XMATCH(A2,$I$5:$I$15),0),
XLOOKUP(F2,row,headers))

But a) what is the meaning of yellow cells, b) why are some cells of "should be" blank? c) what do you mean by "Week number in row 3" - do you mean row 2?
 
Upvote 0
I am not sure whether I understand it correctly. This should return the corresponding week number:

Excel Formula:
=LET(
headers,TOROW(IFERROR(EXPAND(TOROW($J$2:$BB$2,1),5),TOROW($J$2:$BB$2,1)),,1),
row,INDEX($J$5:$BB$15,XMATCH(A2,$I$5:$I$15),0),
XLOOKUP(F2,row,headers))

But a) what is the meaning of yellow cells, b) why are some cells of "should be" blank? c) what do you mean by "Week number in row 3" - do you mean row 2?
a) yellow cells mean nothing. i was just highlighting those cells to show "Mark" has completed number "60" three different times

b) i left a few cells blank in "Should be" for no reason

c) yes my mistake i row 2

The problem I am running into is Mark for example, if he completes number 60 during week 1, week 15, and week 26... it will only ever show Week 1.. Is it possible to show week 1 in G4, Week 15 in G11, Week 26 in G12?
 
Upvote 0
Many thanks for the feedback. Please test this and let me know if it works or not:

Excel Formula:
=LET(
headers,TOROW(IFERROR(EXPAND(TOROW($K$2:$BC$2,1),5),TOROW($K$2:$BC$2,1)),,1),
row,INDEX($K$5:$BC$15,XMATCH(A2,$J$5:$J$15),0),
count,COUNTIFS($A$2:A2,A2,$F$2:F2,F2),
CHOOSECOLS(FILTER(headers,row=F2),count))
 
Upvote 1
Solution

Forum statistics

Threads
1,224,820
Messages
6,181,157
Members
453,021
Latest member
Justyna P

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