greengo204
Technical User
Hi,
I have 2 tables both with a field 'COMPANY_NAME/CUSTOMER_NAME' but they appear in a different format on each table e.g.
I am trying to create a VLOOKUP that can compare the list and return the results from Table A e.g.
Note 1: 'COMPANY_NAME' is consistant in both tables therefore a straight VLOOKUP will work.
Note 2: 'CUSTOMER_NAME' in TableA includes titles (e.g. Mr, Mrs) with no middle names.
Note 3: 'CUSTOMER_NAME' in TableB includes middle names but no titles.
This is what I have so far:
=if(isnumber(search("(",A2),VLOOKUP(LEFT(A2,SEARCH("(",A2)-2)&MID(A2,SEARCH(")",A2)+1,LEN(A2)-(SEARCH(")",A2)+1)), 2 ),tableA,2,0),VLOOKUP(A2,tableA,2,0)
My problem is that tableA is in a diferent format to what I am querying, Is it possible to use VLOOKUP to search within a cell and return a result e.g. does John Smith exist in any cell within column A in tableA if so perform a vlookup on this argument.
Please could some assist me with my formula or suggest an alternative method.
Thanks
Kyle
I have 2 tables both with a field 'COMPANY_NAME/CUSTOMER_NAME' but they appear in a different format on each table e.g.
Code:
tableA
COMPANY_NAME/CUSTOMER_NAME AMOUNT
Mr John Smith 100
Doctor Andrew Brown 500
Microsoft 1000
tableB
COMPANY_NAME/CUSTOMER_NAME AMOUNT
John (Ben)Smith 100
Andrew (Albert) Brown 500
Microsoft 1000
I am trying to create a VLOOKUP that can compare the list and return the results from Table A e.g.
Code:
tableB
COMPANY_NAME/CUSTOMER_NAME AMOUNT VLOOKUP_RESULT
John (Ben)Smith 100 100
Andrew (Albert) Brown 500 500
Microsoft 1000 1000
Note 1: 'COMPANY_NAME' is consistant in both tables therefore a straight VLOOKUP will work.
Note 2: 'CUSTOMER_NAME' in TableA includes titles (e.g. Mr, Mrs) with no middle names.
Note 3: 'CUSTOMER_NAME' in TableB includes middle names but no titles.
This is what I have so far:
=if(isnumber(search("(",A2),VLOOKUP(LEFT(A2,SEARCH("(",A2)-2)&MID(A2,SEARCH(")",A2)+1,LEN(A2)-(SEARCH(")",A2)+1)), 2 ),tableA,2,0),VLOOKUP(A2,tableA,2,0)
My problem is that tableA is in a diferent format to what I am querying, Is it possible to use VLOOKUP to search within a cell and return a result e.g. does John Smith exist in any cell within column A in tableA if so perform a vlookup on this argument.
Please could some assist me with my formula or suggest an alternative method.
Thanks
Kyle