Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi all,
I wanted to replicate the data this lookup function in Excel is pulling, into PowerBI.
=IFNA(VLOOKUP(M2,Table4[#All],2,FALSE),Q2)
For context, M2 is a cell under the column named Project Name, Table 4 is a table that returns a special value if Project Name is detected in it, 2 is where the special value is in Table 4, and Q2 is what I'd like the formula to return if there is an error, which is another line of data.
What would be the equivalent of this Excel formula in PowerBI? Thanks!
Solved! Go to Solution.
Hi @Anonymous
The problem you described is not very clear, maybe you can provide some data or screenshots of the results, which will help us better to deal with the problem .
I created a sample ,maybe you can refer to it .
I created two tables ,table(1) with one value and table(2) with a list of values. And now I want to search in table(2) ,detect whether the value from table(1) in table(2) ,if yes return 2,if no ,return Q2 .
So I created a measure:
Measure = IF(SELECTEDVALUE('Table(1)'[Column1]) in ALL('Table (2)'),2,"Q2")
The effect is as shown :
Best Regards
Community Support Team _ Ailsa Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous
The problem you described is not very clear, maybe you can provide some data or screenshots of the results, which will help us better to deal with the problem .
I created a sample ,maybe you can refer to it .
I created two tables ,table(1) with one value and table(2) with a list of values. And now I want to search in table(2) ,detect whether the value from table(1) in table(2) ,if yes return 2,if no ,return Q2 .
So I created a measure:
Measure = IF(SELECTEDVALUE('Table(1)'[Column1]) in ALL('Table (2)'),2,"Q2")
The effect is as shown :
Best Regards
Community Support Team _ Ailsa Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous ,
In Power BI you should use the LOOKUPVALUE you can see the guide and a video with the explanation on how to use the formula in:
https://dax.guide/lookupvalue/
Without more specific information about your problem is difficult to give you more than this generic link.
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsCovering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
114 | |
100 | |
81 | |
70 | |
62 |
User | Count |
---|---|
148 | |
116 | |
104 | |
90 | |
65 |