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

Get Fabric Certified for FREE during AI Skills Fest. This week only. Secure your voucher now.

Reply
Anonymous
Not applicable

Lookupvalue function returns error

Hello

 

I'm trying to lookup value (list prise) in one input table:

inDiana_0-1622462056218.png

and merge it with the following table

inDiana_3-1622462175113.png

to get the following resul table (list price is the same ragardless the date)

inDiana_2-1622462145944.png

However, Lookupvalue formula returns an error "A table with multiple values was returned when a single value was expected". 

 

Any idea what causes the error and how to solve it?

 

Thank you!

 

1 ACCEPTED SOLUTION
Fowmy
Super User
Super User

@Anonymous 

Check your 1st table for duplicate values  in product column. you try the following as well:

ListPrice = 
MAXX(
    FILTER(
        table-1,
        table-1[product]=EARLIER(table-2[product])
    ),
    table-1[List Price]
)
Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

View solution in original post

3 REPLIES 3
ERD
Community Champion
Community Champion

Hi @Anonymous ,

What formula did you use?

Here is an example for a measure:

#lookupLP = 
LOOKUPVALUE(InputTable[LP], InputTable[Product], MAX(FollowingTable[Product]))

If this post helps, then please consider Accept it as the solution ✔️to help the other members find it more quickly.



If this post helps, then please considerAccept it as the solution to help the other members find it more quickly.
Appreciate your Kudos
Stand with Ukraine! 

Fowmy
Super User
Super User

@Anonymous 

Check your 1st table for duplicate values  in product column. you try the following as well:

ListPrice = 
MAXX(
    FILTER(
        table-1,
        table-1[product]=EARLIER(table-2[product])
    ),
    table-1[List Price]
)
Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

selimovd
Most Valuable Professional
Most Valuable Professional

Hey @Anonymous ,

 

did you create it as a calculated column?

Try the following calculated column:

List Price = LOOKUPVALUE( 'Product'[List price], 'Product'[Product], Retail[Product] )

 

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
 
Best regards
Denis
 

Helpful resources

Announcements
Fabric Data Days is here Carousel

Fabric Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.