Index & Match with Partial string possible?

NGB82KS

Board Regular
Joined
Nov 7, 2019
Messages
82
Office Version
  1. 2016
I have an excel spreadsheet that looks like the below. I need the formula on TAB 1 Column S to calculate if the Class in TAB 1 Column M matches the Master list in TAB 2 Column C, and if that matches, then it looks to see if TAB 1 Column N matches the first 3 characters and if it does return a "Yes" result. (IF TAB 1 Column M matches TAB 2 Column C, & TAB 1 Column N first 3 characters matches TAB 2 Column D first 3 characters)

TAB 1
Class (Column M)Course ID (Column N)FORMULA (Column S)
MATH100 AYES
MATH101 CYES
SCIENCE200 ANO

TAB 2
Master Class (Column C)Master Course ID (Column D)
MATH100 A
MATH100 B
SCIENCE100 1A
 
That is not the formula that Alan suggested in post#3
 
Upvote 0

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.
try this

Book1
ABCDEF
1Math100 AYesMath100 A
2Math101 CNoMath100 B
3Science200 ANoScience100 1A
Sheet2
Cell Formulas
RangeFormula
C1:C3C1=IF(ISNUMBER(MATCH(A1&LEFT(B1,3),$E$1:$E$3&LEFT($F$1:$F$3,3),0)),"Yes","No")
Sorry that code was for yours, his code was
Excel Formula:
=IF(ISNUMBER(MATCH(M2&LEFT(N2,3),Table3[CLASS]&LEFT(Table3[COURSE],3),0)),"Yes","No")
and that gives me all NOs, even if i swap the table and put in the $ reference its still all No
 
Upvote 0
It works for me
+Fluff 1.xlsm
CDEFGHIJKLMNO
1ClassCourseClassCourse IDFORMULA
2MATH100 AMATH100 AYes
3MATH100 BMATH101 CNo
4SCIENCE100 1ASCIENCE200 ANo
5HISTORY200History200 AYes
6HISTORY201
Input
Cell Formulas
RangeFormula
O2:O5O2=IF(ISNUMBER(MATCH(M2&LEFT(N2,3),Table3[Class]&LEFT(Table3[Course],3),0)),"Yes","No")


Try confirming it with Ctrl Shift Enter.
 
Upvote 0
Solution
It works for me
+Fluff 1.xlsm
CDEFGHIJKLMNO
1ClassCourseClassCourse IDFORMULA
2MATH100 AMATH100 AYes
3MATH100 BMATH101 CNo
4SCIENCE100 1ASCIENCE200 ANo
5HISTORY200History200 AYes
6HISTORY201
Input
Cell Formulas
RangeFormula
O2:O5O2=IF(ISNUMBER(MATCH(M2&LEFT(N2,3),Table3[Class]&LEFT(Table3[Course],3),0)),"Yes","No")


Try confirming it with Ctrl Shift Enter.
OK, WELL CONTROL SHIFT ENTER CHANGED EVERYTHING FROM NO WHAT IT APPEARS ITS SUPPOSED TO BE.... DARK EXCEL MAGIC WIZARDY I TELL YOU
 
Upvote 0
Glad we could help & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,224,827
Messages
6,181,199
Members
453,022
Latest member
RobertV1609

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