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! Learn more

Reply
RMV
Helper V
Helper V

lookup with 2 search columns

Hi, I need to get a value from another table, with 2 search columns I tried to use this formula: LOOKUPVALUE = (Table2[ColumnToRetrieve], Table2[Entity], Table1[Entity], Table2[No.], Table1[No.]) for example: Table2 Entity No. ColumnToRetrieve A 1 2000 B 2 3000 What I need in Table1 Transaction Entity No. ColumnToRetrieve 123 A 1 2000 234 A 1 2000 345 B 2 3000 However, the formula I'm currently using returns blank value at Table1. Need advise what formula should I use. Thanks

7 REPLIES 7
RMV
Helper V
Helper V


@RMV wrote:

Hi, I need to get a value from another table, with 2 search columns I tried to use this formula: LOOKUPVALUE = (Table2[ColumnToRetrieve], Table2[Entity], Table1[Entity], Table2[No.], Table1[No.]) for example: Table2 Entity No. ColumnToRetrieve A 1 2000 B 2 3000 What I need in Table1 Transaction Entity No. ColumnToRetrieve 123 A 1 2000 234 A 1 2000 345 B 2 3000 However, the formula I'm currently using returns blank value at Table1. Need advise what formula should I use. Thanks


 

Hi,

I need to get a value from another table, with 2 search columns

I tried to use this formula:

LOOKUPVALUE = (Table2[ColumnToRetrieve], Table2[Entity], Table1[Entity], Table2[No.], Table1[No.])

 

for example:

Table2

Entity     No.      ColumnToRetrieve

A             1           2000

B             2           3000

 

What I need in Table1

Transaction    Entity    No.    ColumnToRetrieve

123                  A          1        2000

234                  A          1        2000

345                  B           2       3000

 

However, the formula I'm currently using returns blank value at Table1.

Need advise what formula should I use. Thanks

Hi @RMV,

 

This works fine for me

 

=LOOKUPVALUE(Table2[ColumnToRetrieve],Table2[Entity],[Entity],Table2[No.],[No.])

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Try This

=
CALCULATE (
    VALUES ( Table2[ColumnToRetrieve] ),
    FILTER ( Table2, Table2[Entity] = Table1[Entity] && Table2[No.] = Table1[No.] )
)

Hi @Zubair_Muhammad,

 

Tried your advise.

However, when I used the formula, the columns at Table1 is not recognized.

Need further advise. Thanks.

 

 

 

Hi @RMV

Please type the formula and use Power BI's intelliesense to select Table1 Columns.

It could be that you copied and pasted the formula and there was a slight difference in column names.

This formula works fine with me with your data.

 

Hi @Zubair_Muhammad@Ashish_Mathur,

 

Tried both of your formula. I typed it, and not just copy paste it.

But, I still can't manage it.

Do I have to create relationship first, or is there anything I need to look at?

Hi @RMV

 

What error do you get this time?

Could you embed an image of Table2 in Power Pivot Data Model?

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