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.
Looking for a way to include a If statement with multiple conditions into Power BI. Example
If Column B is 2 numbers greater than Column A be than investigate. otherwise Do Not Investigate.
example of what I am looking to do.
A B C
1 3 Investigate
2 2 Do Not Investigate
5 6 Do Not Investigate
7 9 Investigate
8 9 Do Not Investigate
Solved! Go to Solution.
Below dax can be used as per your example:
Column =
IF(
B > A + 2,
"Investigate",
"Do Not Investigate"
)
You can use nested If statement to have multiple conditions as shown below:
Price Group =
IF(
'Product'[List Price] < 500,
"Low",
IF(
'Product'[List Price] < 1500,
"Medium",
"High"
)
)
Hope this helps
Below dax can be used as per your example:
Column =
IF(
B > A + 2,
"Investigate",
"Do Not Investigate"
)
You can use nested If statement to have multiple conditions as shown below:
Price Group =
IF(
'Product'[List Price] < 500,
"Low",
IF(
'Product'[List Price] < 1500,
"Medium",
"High"
)
)
Hope this helps
@Anonymous
Try:
New measure =
VAR Diff = SUM('Table'[B]) - SUM('Table'[A])
RETURN
SWITCH(TRUE(),
Diff >= 2, "Investigate",
"Do Not Investigate")
Proud to be a Super User!
Paul on Linkedin.
You can do this by creating a column and using the following If formula:
C = if(('Table '[b] - 'Table '[a]) = 2, "Investigate", "Do Not Investigate")
Hope this help you
Have a great day
Covering 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 |
---|---|
107 | |
98 | |
77 | |
64 | |
58 |
User | Count |
---|---|
148 | |
113 | |
97 | |
84 | |
67 |