Get certified in Microsoft Fabric—for free! For a limited time, the Microsoft Fabric Community team will be offering free DP-600 exam vouchers. Prepare now
Hello All,
I have a requirement wherein I have used LOOKVALUE to get the numbers from different table. However i have similar data in the main table which has resulted in getting the same number everywhere.
I would like to get only first number (4440) and make others as 0 or blank. As i need to sum the column which will result in wrong numbers if i use just lookupvalue function.
Try this:
MAXX (
FILTER ( SearchTable, SearchTable[Product] = ThisTable[Product] ),
SearchTable[Category]
)
Hi @nagaraj007
LOOKUPVALUE should only be used when there is a single value for what is being looked up (otherwise it will return an error); to return the "first" value you need to define what makes it the first value - the first corresponding ID, or the lowest value? (if you don't have anything you can add an index column in the query editor)...then you need to use a measure to sum the corresponding values for each item by applying filters for the first item and any other context you want to restrict it to. If you post an example dataset I can show you an example of such a measure?
Thanks
Rishi
Check out the October 2024 Power BI update to learn about new features.
Learn from experts, get hands-on experience, and win awesome prizes.
User | Count |
---|---|
115 | |
112 | |
105 | |
95 | |
58 |
User | Count |
---|---|
174 | |
147 | |
136 | |
102 | |
82 |