If cell contains partial text return value from other cell

9191w

New Member
Joined
Aug 31, 2017
Messages
13
Hey!

I have 3 cells, 2 are with names, they are not sorted, as they are extracted from two different webpages.

Basically eg.
Cell 1 (full namem, random order): Masahiko Inoha
Cell 2 (partial name, usually the following): M. Inoha (in some cases however full names)
Cell 3 (extracted web code, on the same row as cell 2): 3445

Now I want the value of Cell 3 to align with Cell 1 through a partial match with cell 2.

I used: =IF(ISNUMBER(SEARCH(C:C,K3)),N3), and tried VLOOKUP variations too but without success.

Thank your for your time!
 

Excel Facts

Workdays for a market open Mon, Wed, Friday?
Yes! Use "0101011" for the weekend argument in NETWORKDAYS.INTL or WORKDAY.INTL. The 7 digits start on Monday. 1 means it is a weekend.
Excel 2010
ABCDEFGHIJKLMN
1
2
3Masahiko Inoha3445<< Formula Extracts from Cell K3 the Right-Most Single Name OnlyM. Inoha3445
4 and searches for it In Cell D3 AND If Found returns the
5Value in Cell N (Same row).

<tbody>
</tbody>
Sheet1

Worksheet Formulas
CellFormula
D3=IF(SEARCH(RIGHT(K3,LEN(K3)-FIND(" ",K3)),C3,1),N3,"")

<tbody>
</tbody>

<tbody>
</tbody>
 
Upvote 0
Many thanks for your quick response!

Apologies for not explaining myself properly. Column K is not sorted in the same way as C is, it's all mixed up. How would I need to change the above to solve that? Didn't manage myself.

Best
 
Upvote 0
Just to add, my aim is to sort it by column C, so that I have the fitting number codes per name that fit to C.
 
Upvote 0
Supply a Table of Data Sufficient in size to prepare and solve the problem, please.
 
Upvote 0
CDEFGHIJKLMN
Hiroki Mizumotohiroki-mizumoto49348hiroki-mizumoto/profil/spieler/49348
Patrichttps://instatscout.com/en/players/48629null48629
Daiki Niwadaiki-niwa79706daiki-niwa/profil/spieler/79706
T. Miyayoshihttps://instatscout.com/en/players/144081null144081

<tbody>
</tbody>
<style type="text/css"><!--td {border: 1px solid #ccc;}br {mso-data-placement:same-cell;}--></style>
Kazuyuki Morisakikazuyuki-morisaki106069kazuyuki-morisaki/profil/spieler/106069
T. Matsumotohttps://instatscout.com/en/players/486368null486368
Ryotaro Hironagaryotaro-hironaga113621ryotaro-hironaga/profil/spieler/113621
T. Aoyamahttps://instatscout.com/en/players/30056null30056
Hirotsugu Nakabayashi
hirotsugu-nakabayashi106272hirotsugu-nakabayashi/profil/spieler/106272
T. Morishimahttps://instatscout.com/en/players/283017null283017
Masato Kudomasato-kudo114202masato-kudo/profil/spieler/114202
Y. Chajimahttps://instatscout.com/en/players/222766null222766
Osamu Henry Iyoha
osamu-henry-iyoha332628osamu-henry-iyoha/profil/spieler/332628
K. Mukuharahttps://instatscout.com/en/players/35033null35033
Takumi Miyayoshi
takumi-miyayoshi79742takumi-miyayoshi/profil/spieler/79742
S. Inagakihttps://instatscout.com/en/players/222763null222763
Kazuhiko Chibakazuhiko-chiba31065kazuhiko-chiba/profil/spieler/31065
S. Takahashihttps://instatscout.com/en/players/232655null232655
Takuto Hayashitakuto-hayashi126383takuto-hayashi/profil/spieler/126383
Y. Nogamihttps://instatscout.com/en/players/173318null173318
Nathan Burnsnathan-burns43087nathan-burns/profil/spieler/43087
K. Chibahttps://instatscout.com/en/players/30008null30008

<tbody>
</tbody>

Hope the above works in format. Bit chaotic as I was scraping two webpages, list goes on for about 1000 rows.

Column C, K & N is of interest, ignore the rest. K (short name) + N (code) are matching in each row.

C is mixed and I wish to match them with the corresponding code per name in N. So that basically the code shows up in column E for each player corresponding in the same row in C.

Hope all makes sense, many thanks for your time!
 
Last edited by a moderator:
Upvote 0
Here are your C, N, and K records...

Row\Col
C​
K​
N​
5​
Hiroki MizumotoPatric
48629
6​
Daiki NiwaT. Miyayoshi
144081
7​
Kazuyuki MorisakiT. Matsumoto
486368
8​
Ryotaro HironagaT. Aoyama
30056
9​
Hirotsugu NakabayashiT. Morishima
283017
10​
Masato KudoY. Chajima
222766
11​
Osamu Henry IyohaK. Mukuhara
35033
12​
Takumi MiyayoshiS. Inagaki
222763
13​
Kazuhiko ChibaS. Takahashi
232655
14​
Takuto HayashiY. Nogami
173318
15​
Nathan BurnsK. Chiba
30008

What is the output that you require?
 
Upvote 0
Thank you for taking the time to put it in a better format!

Column K & N are fitting, eg. N5 is the actual code of the person named "Patric" (K5). In C the same name of lists (but full names instead) comes but in mixed order. I aim to have the code of column N match with each name in column C outputted in column E.

In the short sample above only C12 fits with K6/N6, C13 fits with K15/N15 - the others would appear more down the columns.

Best
 
Upvote 0
Thank you for taking the time to put it in a better format!

Column K & N are fitting, eg. N5 is the actual code of the person named "Patric" (K5). In C the same name of lists (but full names instead) comes but in mixed order. I aim to have the code of column N match with each name in column C outputted in column E.

In the short sample above only C12 fits with K6/N6, C13 fits with K15/N15 - the others would appear more down the columns.

Best

In E5 enter and copy down:

=IFERROR(VLOOKUP("*"&IF(ISNUMBER(FIND(".",K5)),REPLACE(K5,1,FIND(".",K5),""),K5)&"*",CHOOSE({1,2},$C$5:$C$15,$N$5:$N$15),2,0),"NA")
 
Upvote 0

Forum statistics

Threads
1,216,151
Messages
6,129,162
Members
449,489
Latest member
spvclub

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