Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hello Folks, I am brand new to Power bi and am trying to get through learning it. I wrote the following DAX formula - "Customer Order Amount = LOOKUPVALUE('Stock Inventory'[Unit Price],'Stock Inventory'[SKU ID],'Weekly Demand Sheet'[SKU ID])*'Weekly Demand Sheet'[Weeks Demand]) - I receive the following error - "A table of multiple values was supplied where a single value was expected" -
I am so frustrated (NOOBITIS) - I can't figure out how to fix this, so I can create my forecasting - can anyone help? I will be most grateful
Helen
Solved! Go to Solution.
Hi , @HEHuggins
According to your description, when you use the LOOKUPVALUE() function, an error is reported. Right?
For this function, if we use the associated field to match multiple values, it will report an error, and I reproduced this error through test data.
My test data is this:
Since we want to get the [Unit Price] field in the Stock Inventory table, but we have two values [SKU ID]=4 in the table, the engine cannot tell which value needs to be obtained, resulting in an error:
For the case of duplicate values, we need to choose the maximum or minimum value according to the actual needs, and we can use the following measures to solve this problem:
Column = var _cuurent_id = 'Weekly Demand Sheet'[SKU ID]
var _t= FILTER('Stock Inventory','Stock Inventory'[SKU ID]= _cuurent_id)
var _unit_price = MAXX(_t ,[Unit Price])
return
_unit_price
The result is as follows:
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi , @HEHuggins
According to your description, when you use the LOOKUPVALUE() function, an error is reported. Right?
For this function, if we use the associated field to match multiple values, it will report an error, and I reproduced this error through test data.
My test data is this:
Since we want to get the [Unit Price] field in the Stock Inventory table, but we have two values [SKU ID]=4 in the table, the engine cannot tell which value needs to be obtained, resulting in an error:
For the case of duplicate values, we need to choose the maximum or minimum value according to the actual needs, and we can use the following measures to solve this problem:
Column = var _cuurent_id = 'Weekly Demand Sheet'[SKU ID]
var _t= FILTER('Stock Inventory','Stock Inventory'[SKU ID]= _cuurent_id)
var _unit_price = MAXX(_t ,[Unit Price])
return
_unit_price
The result is as follows:
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
I was wanting it to caluculate the demand - so weeks demand x unit price =
but I used this and then just added another column multiplying the two - so thank you 😄
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
11 | |
9 | |
8 | |
8 | |
8 |
User | Count |
---|---|
13 | |
12 | |
11 | |
10 | |
9 |