Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
alicia_pbi
Microsoft Employee
Microsoft Employee

Vlookup/Lookup Value in Query Editor/M Language

Hello,

 

Is there a way to do a vlookup/lookup value calculation in the query editor using M Language?  I believe the Merge function is one way to acheive this.  However in my dataset that I am trying to bring data into contains duplicates.  The dataset I am looking the data up in also contains duplicates so I get an error with the Merge.  Generally speaking I understand I shouldn't have duplicates in both data sets however the value I am trying to retreive via vlookup/lookup value is the same regardless of the duplicate values.  I cannot group or otherwise parse my query dataset down to exclude duplicates because I need this data for other visuals in my model.  I could create another query I realize but then I have to make the data sets related in order to make my already complex model function correctly so I belive the lookup value is the easiest.  I understand I can do this in DAX but I wanted to know if I could do it in the Query Editor also.

 

Thanks in advance!

3 REPLIES 3
Aron_Moore
Solution Specialist
Solution Specialist

Merge is the way to go. Duplicate the query where you want the lookup values and then disable the load so it doesn't come into your model.

@Aron_Moore  thanks for the reply.  If I disable the load will new changes come in?  The query I am specifically thinking about is a list of employees so I need to make sure it is refreshing to add new employess.

 

Thanks again!

Yes, it will continue to refresh along with your other data. Disabling the load just prevents the table from coming into your model.

See https://community.powerbi.com/t5/Desktop/Getting-rid-of-source-tables-after-append/td-p/154745

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors