Xlookup with first characters

ecrodrig

Board Regular
Joined
Jan 21, 2022
Messages
99
Office Version
  1. 365
Platform
  1. Windows
  2. MacOS
I am attaching my file here. If you notice I have on column B a formula for left that takes the firs 9 characters and gives me that name. This works great except that this is inside a power query table. whenever I do a refresh on the power query I get a #REF error because for some insane reason it isn't finding the column although the column never changes only the input within the row changes. With that said I am trying to do the same thing but with an xlookup. I would like to look for the name in Column D but only the first 9 characters of that name and then I need the output to be those first 9 characters.

I hope I explained it correctly. here is my attempt:

Sample_File_forecast1.xlsx
ABCDE
1First CharactersProject NameNew Business (RFS)Total Charges
2Project 1project 1#N/Aproject 1 name602.95
3Project 2project 2project 2 name363.5
4Project 3project 3project 3 name1500
5Project 4project 4project 4 name2520
6Project 5project 5project 5 name5500
7total10486.45
T&M
Cell Formulas
RangeFormula
C2C2=XLOOKUP('T&MMthlyFile'!B:B,'T&MMthlyFile'!A:A,'T&MMthlyFile'!B:B)
B2:B6B2=LEFT(D2,9)
E7E7=SUM(E2:E6)
 

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.
Hi there

What happens if you change

VBA Code:
=LEFT(D2,9)
to
Excel Formula:
=LEFT([@[New Business (RFS)]],9)
 
Upvote 0

Forum statistics

Threads
1,216,487
Messages
6,130,944
Members
449,608
Latest member
jacobmudombe

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