Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
rohan_mate
Regular Visitor

KPI Indicator - Circular Dependency Issue

Hey Guys,

 

I'm trying to build a KPI indicator inside the table visual, learning from the 

https://dataveld.com/2018/07/16/use-svg-images-in-power-bi-part-3. I have put foward the below KPI,

 

KPI =
VAR MessageTextComplete = LOOKUPVALUE('HR Tracking Tool'[Quater year],[Current Status],"Complete")
VAR MessageTextBehind = LOOKUPVALUE('HR Tracking Tool'[Quater year],[Current Status],"In Progress - Behind")
VAR MessageTextTrack = LOOKUPVALUE('HR Tracking Tool'[Quater year],[Current Status],"In Progress - Tracking Well")
VAR MessageText = ""
VAR Radius = 9
VAR ColorRed ="red"
VAR ColorBlue ="blue"
VAR ColorGreen ="green"
VAR ColorYellow ="yellow"
VAR Opacity = 0.75
VAR Neutral="data&colon;image/svg+xml;utf-8," & "<svg xmlns='http://www.w3.org/2000/svg' x=’0px’ y=’0px’ width=’50’ height=’20’>"
& "<circle cx='25' cy='10' r='"
& Radius
& "' fill='"
& ColorRed
& "' fill-opacity='"
& Opacity
& "' />"
& "<text x='15%' y='95%' text-anchor='bottom' font-family='Verdana' font-size='8px'>" & MessageText & "</text>"
& "</svg>"
VAR Complete = "data&colon;image/svg+xml;utf8,"
& "<svg xmlns='http://www.w3.org/2000/svg' x='0px' y='0px' width='50' height='35'>"
& "<circle cx='25' cy='10' r='"
& Radius
& "' fill='"
& ColorBlue
& "' fill-opacity='"
& Opacity
& "' />"
& "<text x='15%' y='95%' text-anchor='bottom' font-family='Verdana' font-size='8px'>" & MessageTextComplete & "</text>"
& "</svg>"
VAR InProgressBehind = "data&colon;image/svg+xml;utf8,"
& "<svg xmlns='http://www.w3.org/2000/svg' x='0px' y='0px' width='50' height='35'>"
& "<circle cx='25' cy='10' r='"
& Radius
& "' fill='"
& ColorYellow
& "' fill-opacity='"
& Opacity
& "' />"
& "<text x='15%' y='95%' text-anchor='bottom' font-family='Verdana' font-size='8px'>" & MessageText & "</text>"
& "</svg>"
VAR InProgressTracking = "data&colon;image/svg+xml;utf8,"
& "<svg xmlns='http://www.w3.org/2000/svg' x='0px' y='0px' width='50' height='35'>"
& "<circle cx='25' cy='10' r='"
& Radius
& "' fill='"
& ColorGreen
& "' fill-opacity='"
& Opacity
& "' />"
& "<text x='15%' y='95%' text-anchor='bottom' font-family='Verdana' font-size='8px'>" & MessageTextTrack & "</text>"
& "</svg>"
RETURN
SWITCH (
TRUE (),
SUM('HR Tracking Tool'[Color Label]) =4, Complete,
SUM('HR Tracking Tool'[Color Label]) =2, InProgressBehind,
SUM('HR Tracking Tool'[Color Label]) =3, InProgressTracking,
Neutral)
 
I tried using different DAX functions such as VALUES and FORMAT but its still giving circular dependency issue.
 
I'm trying to get below output
output expected to look from KPIoutput expected to look from KPI
 
Or if there is any other better way to achieve this, I'm open to try it.
 
Can some one please help
 
0 REPLIES 0

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.