Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi in need of some assistance.
I need a code (first thing that comes to mind is an if statement) for the following:
IF total expenditure = $5000000 and below "low risk", IF total expenditure = $5000001 - $10000000, "Medium Risk", IF total expenditure = $10000001+, "High Risk"
The Power Bi visualisation being used is a card and I need it linked to another card that displays the total expenditure in a report.
Thanks!!
Solved! Go to Solution.
Just need to use a card with states--this is a custom visual.
You can download from here.
https://app.powerbi.com/visuals/
I attach a sample of your case:
Hi, Create a Measure
Risk_State =
IF (
SUM ( 'TableName'[Expenditure] ) < 5000000,
"low risk",
IF (
SUM ( 'TableName'[Expenditure] ) < 10000000,
"Medium Risk",
"High Risk"
)
)
G'day mate,
That worked but I gave you the wrong instructions my apologies. Here is how i'd like my report to work:
- I have two page slicers, one for the financial year change and the other for "On Contract Spend" and "Off Contract Spend".
- I have the following cards:
Card 1 Total Spend (column is expenditure)
Card 2 Spend Off Contract (column is expenditure with an additional filter of Off and On Contract column)
Card 3 Risk Rating Low $5mil and below, Med $10mil to $5mil and High $10mil+. I would like this to be linked somehow just to card 2 if possible.
Would even be cooler if I could change colours ie low risk is green, med risk is orange and high is red.
Thanks for your help!!
Just need to use a card with states--this is a custom visual.
You can download from here.
https://app.powerbi.com/visuals/
I attach a sample of your case:
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!